I ended up committing a slightly different version (which does pkgname-sub
directly), since it's easy to check by inspection that nothing changes.

I'm 1/4th of the way through cleaning up existing ports (where a lot of
explicit PKGNAME-sub is now unneeded).

The documentation part in bsd.port.mk(5) is done as well

in a nutshell,
assuming

DISTNAME = foo-1.0

if you have MULTI_PACKAGES = -main -gtk -server

then PKGNAMEs get default values, namely:

PKGNAME-main = foo-1.0  (so yeah, -main is slightly special)
PKGNAME-gtk = foo-gtk-1.0
PKGNAME-server = foo-server-1.0

apart from ports that have weird correspondences (say a SUBPACKAGE -plugin
that yields a -termin name), and of ports with specific naming conventions
(prepending py3-  to a -python subpackage), a lot of MULTI_PACKAGES ports
will no longer require any specific love to set the correct PKGNAMEs.

Remember:
make show=PKGNAMES
will give you the current set of names.

Reply via email to