On Thu, 12 Nov 2015 16:15:35 +0100
Marc Espie <[email protected]> wrote:

> On Wed, Nov 11, 2015 at 05:13:45PM +0100, Adam Wolk wrote:
> > Hi tech@,
> > 
> > I have been working recently on packaging a shared library for the
> > first time and hit a stumbling block yesterday.
> > 
> > $ make package
> > `/usr/ports/pobj/libwebsockets-1.5/fake-amd64/.fake_done' is up to
> > date. ===>  Building package for libwebsockets-1.5  
> > Create /usr/ports/packages/amd64/all/libwebsockets-1.5.tgz
> > reading plist|
> > Error: Invalid shared library @lib lib/libwebsockets.so.5  
> 
> I'm pretty sure the naming scheme is out of place in the error
> message. But yeah, the message is not perfect.

Maybe then just adding a name would help here? It is a bit difficult to
handle since the code checks both that the file matches the naming
scheme & that it's located in at least one sub-folder.

Leaving it up to you. I know what to do next time I spot that. Thought
it would be easier for someone else to understand the error when hit.

Regards,
Adam

Index: OpenBSD/PkgCreate.pm
===================================================================
RCS file: /cvs/src/usr.sbin/pkg_add/OpenBSD/PkgCreate.pm,v
retrieving revision 1.118
diff -u -p -r1.118 PkgCreate.pm
--- OpenBSD/PkgCreate.pm        6 Nov 2015 08:53:12 -0000       1.118
+++ OpenBSD/PkgCreate.pm        11 Nov 2015 16:07:33 -0000
@@ -674,7 +674,7 @@ sub check_version
                        $state->error("Incorrectly versioned shared library: 
#1", $unsubst);
                }
        } else {
-               $state->error("Invalid shared library #1", $unsubst);
+               $state->error("Invalid shared library name #1", $unsubst);
        }
        $state->{has_libraries} = 1;
 }

Reply via email to