[73039] trunk/dports/_resources/port1.0/group/qt4-1.0.tcl
Ryan Schmidt
ryandesign at macports.org
Fri Nov 5 07:25:31 PDT 2010
On Nov 5, 2010, at 08:49, Michael Dickens wrote:
> On Nov 1, 2010, at 6:00 PM, jmr at macports.org wrote:
>> qt4 portgroup: fix qt_arch_types so it doesn't only exist in the patch phase
>> Modified Paths
>>
>> --- trunk/dports/_resources/port1.0/group/qt4-1.0.tcl 2010-11-01 21:54:50 UTC (rev 73038)
>> +++ trunk/dports/_resources/port1.0/group/qt4-1.0.tcl 2010-11-01 22:00:03 UTC (rev 73039)
>>
>> -DQT_PNG_LIBRARY=${prefix}/lib/libpng.dylib"
>> # set Qt understood arch types, based on user preference
>> +options qt_arch_types
>> +default qt_arch_types {[string map {i386 x86} [get_canonical_archs]]}
>
> I just updated to the latest SVN version of 'port', and "get_canonical_archs" no longer works for me (it did from 'port' just a few weeks old): it is always set to the native compile arch no matter if I specify +universal or anything else. Any other suggestions on how to globally set arch types? I can always revert back to using a 'proc' that is sets the option/global, which would then be correctly set & available for use.
>
> Another question related to this: what is the difference between a 'global' variable versus an 'options' one?
options/default gives you delayed substitution whereas a normal global variable has any substitutions done immediately.
Delayed substitution is how MacPorts does the magic that makes worksrcdir default to ${distname}, for example. worksrcdir is not expanded to ${distname} at the point where this definition is made in MacPorts base; rather, it is expanded the first time ${worksrcdir} is used. This is what enables a portfile to override distname and have that also cause worksrcdir to be overridden.
I am not certain why this change is causing a problem for you in this portgroup.
More information about the macports-dev
mailing list