On 2009/08/12 20:35, frantisek holop wrote: > hi there, > > i am having trouble understanding LIB_DEPENDS vs WANTLIB. > i always thought that WANTLIB is only for system libraries, > i.e. libraries that come with openbsd. > > library-specs(7) says: > > All libraries that a port needs must be mentioned in that list, either > directly or indirectly through recursive dependencies (except, of course, > for system libraries). > > bsd.port.mk(5) says: > > WANTLIB Extra list of library specifications that a package will > need. May include system and X11 libraries. > > As a special extension, WANTLIB may include absolute paths, > e.g., ${LOCALBASE}/lib/expat.=4 to distinguish between base > libraries and port libraries. Use with caution, this is > very seldom needed.
it also says: LIB_DEPENDS Libraries this port depends upon. Each item has the form `lib_specs:[pkgspec]:directory[,-subpackage][,flavor ...][:target]'. Similar to BUILD_DEPENDS, except for `lib_specs', which is a comma-separated list of `lib_spec' of the form: `libname.[version.[subversion]]'. See library-specs(7) for more details. these have to be read together really; LIB_DEPENDS are libraries from ports/packages which the port depends on drectly, WANTLIB are the extra libraries that a package will need, which it does not depend on directly (the user installing a particular package must have these libraries present and at the correct version, i.e. the same major, and lower or equal minor, as that package was built against). these all show up in objdump -p as 'NEEDED' entries (indirect dep's show the full path in the output; this is how "make {port-,}lib-depends-check" tells them apart).