DEPENDS -- is it time to remove it?

Matthew Seaman m.seaman at
Thu Jan 4 06:02:21 PST 2007

Dear all,

The ports make infrastructure has a whole series of variables for showing
how one port depends on another: LIB_DEPENDS, BUILD_DEPENDS, RUN_DEPENDS
etc.  Amongst these is what looks to me like the vestigial remnant of
an earlier phase of the ports: the plain, unmodified 'DEPENDS' variable.

This seems to have an effect apparently like all of the other DEPENDS
variants rolled together, but unlike the others you can't give it a
filename or a shlib to use as a test that whatever it references has
been installed, so it always causes its target to be installed.

The Porter's Handbook says (Section 5.7.10):

   "Do not use DEPENDS unless there is no other way the behaviour you want
    can be accomplished. It will cause the other port to always be built
    (and installed, by default), and the dependency will go into the
    packages as well. If this is really what you need, you should probably
    write it as BUILD_DEPENDS and RUN_DEPENDS instead--at least the
    intention will be clear."

Plus it seems that there is nowadays a grand total of just 3 ports out
of 16,300 or so that actually uses this variable:

happy-idiot-talk:/usr/ports:% grep -re '^DEPENDS\>' .
./audio/klira/Makefile:DEPENDS= ${PORTSDIR}/misc/kdehier            [*]
./www/caudium12/Makefile:DEPENDS=       ${PORTSDIR}/lang/pexts/
./x11/kdelibs3/Makefile:DEPENDS=        ${PORTSDIR}/misc/kdehier

Practically, removing DEPENDS would simplify (slightly) the logic in and make generating the INDEX-n file a bit faster.



[*] audio/klira is an oddity: all but two other KDE apps inherit their
dependency on kdehier through depending on kdelibs3.  The two other
exceptions, both of which have a RUN_DEPENDS directly on kdehier, are
math/proofgeneral (deprecated, due for removal on 2007-02-07) and
sysutils/kports (which also depends on kdelibs, so doesn't need the
direct dependency as well).

Dr Matthew J Seaman MA, D.Phil.                       7 Priory Courtyard
                                                      Flat 3
PGP:         Ramsgate
                                                      Kent, CT11 9PW

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 250 bytes
Desc: OpenPGP digital signature
Url :

More information about the freebsd-ports mailing list