in-Portfile variant removal (not default)?
Joshua Root
jmr at macports.org
Fri Jul 23 15:37:19 PDT 2010
On 2010-7-24 06:11 , Michael Dickens wrote:
> For qt4-4.6.3, if I configure as +framework and +debug, 'configure' will
> internally change the latter into +combined (meaning: debug and
> release); in 4.7.0b2 with these variants, 'configure' prints an error
> and exits. I'm inserting some "ui_msg"s into the qt4-* Portfiles to
> explain what's going on -- warning the user and/or providing info as to
> how to use features of the install (e.g., getting access to the
> FOO_debug libraries when executables are linked to FOO framework). So,
> what I'd like to do is change variants inside the Portfile from +debug
> to +combined; I'm sure it's possible, I just don't know how & quick
> search of Portfiles and the MacPorts Guide have come up empty (and, it's
> possible I was too quick in looking). I've tested the addition of
> +combined and that works (via "default_variants" in side "if"
> statements). But how do I remove the user-specified +debug variant?
> Thanks! - MLD
Why not just declare debug as conflicting with framework? Silently
giving the user different variants than they requested isn't good UI.
Maybe also have combined require debug, since you do get debug versions
with it. Or have a variant like no_optimized instead (that requires
debug), and have the behaviour be that no variants builds an optimized
version, +debug adds a debug version, and +no_optimized turns off the
optimized version leaving you with just the debug one. (Framework should
then conflict with no_optimized.)
- Josh
More information about the macports-dev
mailing list