portfile question concerning optional deps

Marko Käning MK-MacPorts at techno.ms
Thu Mar 3 13:52:50 PST 2011


Hi,

I am thinking about enabling a portfile to allow for two alternative ports as dependencies.

Say, I have the ports 
 - A
 - B-release
 - B-devel

I want A to be dependent on either B-release or B-devel, exclusively!

To tell the port which version of B-* to use is fairly simple due to variants.

BUT…

Say, the user has installed B-devel before installing port A: In that case I want to let port A accept B-devel as the default dep.

If, however, B-release is installed, than that one should be accepted.

How can I test in the portfile for already installed ports?

Greets,
Marko


More information about the macports-dev mailing list