RFC: FreeBSD DB Port Reform

Oliver Eikemeier eikemeier at fillmore-labs.com
Thu Nov 6 04:15:54 PST 2003

Hi Matthias,

>     2. bsd.ports.mk should be extended to support WITH_BDB_VER,
>        USE_BDB_VER or WANT_BDB_VER or something that presets a set of
>        variables, for instance BDB_VERSION, BDB_INCLUDES, BDB_LIBNAME,
>        BDB_LIBPATH and LIB_DEPENDS, to lift shared code out of the
>        individual ports into bsd.ports.mk.
No WITH_* options in bsd.ports.mk, they are supposed to use as make arguments
to communicate user => port.

>     3. for db3, db4 and db41, the following changes are made:
>          1. all programs move into $PREFIX/BerkeleyDB.N.M/bin/db_*
That violates hier(7). How about moving them to libexec?

>          4. all libraries move into $PREFIX/BerkeleyDB.N.M/lib, because
>             BerkeleyDB installs not only libdb-N.M* but also libdb-N* and
>             libdb* (where * is .so.N, .so or .a), which cannot work in
>             the same path.
Same as above. How about lib/db-N.M?

>          5. a relative symbolic link from $PREFIX/lib/libdb-N.M.so.M to
>             ../BerkeleyDB.N.M/lib/libdb-N.M.so.M (the SONAME, see above)
>             is maintained.
>          6. documentation moves into $PREFIX/share/doc/BerkeleyDB.N.M and
>             is symlinked from $PREFIX/BerkeleyDB.N.M/docs
The symlink should not be necessary.

Could you explain stupid people like me again what you gain by not simply
renaming the libraries to libdb-3.3, libdb-4.0 and libdb-4.1 and leaving
the other stuff as it is now?

IMHO ports that expect a BerkeleyDB.N.M directory under /usr/local violate
hier(7), and does this approach work with the ldconfig -r LIB_DEPENDS checking
we have in bsd.port.mk?

More information about the freebsd-ports mailing list