[76805] trunk/dports/gis/qgis/Portfile
Ryan Schmidt
ryandesign at macports.org
Wed Mar 9 23:45:46 PST 2011
On Mar 10, 2011, at 00:33, Joshua Root wrote:
>> Revision: 76805
>> http://trac.macports.org/changeset/76805
>> Author: vince at macports.org
>> Date: 2011-03-09 00:14:29 -0800 (Wed, 09 Mar 2011)
> [...]
>> Modified: trunk/dports/gis/qgis/Portfile
>> ===================================================================
>> --- trunk/dports/gis/qgis/Portfile 2011-03-09 06:41:43 UTC (rev 76804)
>> +++ trunk/dports/gis/qgis/Portfile 2011-03-09 08:14:29 UTC (rev 76805)
> [...]
>> @@ -47,20 +43,79 @@
> [...]
>> +pre-extract {
>> + # At least one python package must be specified
>> + if {[lsearch [split ${portvariants} "+"] "python*"] == -1} {
>> + ui_error "Qgis requires python. Please select a variant."
>> + exit 0
>> + }
>> +}
> [...]
>> + if {[variant_isset universal] && ${Pyversion} < 26} {
>> + ui_error "Universal build requires Python > 2.5"
>> + exit 0
>> }
>
> Please don't use exit in a portfile. Throw an error instead.
Instead of exit 0, use:
return -code error "short message"
"short message" might be something like "incompatible variants" since you already explain the problem in greater detail in your ui_error.
More information about the macports-dev
mailing list