I would suggest that we avoid using conditionals based on 'sw_vers
-productionVersion' altogether and use `uname -r | cut -d. -f1` to
compare the major darwin release number instead as that future-proofs
us against any potential bump in the OS X release version beyond 10.

On Sat, Nov 29, 2014 at 6:25 PM, Jack Howarth <howarth.at.f...@gmail.com> wrote:
>    The failure of the inkscape-0.48.5-4 build exposed the fact that
> the commonly used conditional...
>
>         if [[ $(sw_vers -productVersion | cut -d. -f1-2) > 10.8 ]]; then
>
> is failing on 10.10 and needs to be replaced with...
>
>         if [ $(sw_vers -productVersion | cut -d. -f2) > 8 ]; then
>
> This conditional is used in the following packages...
>
> % grep -R "f1-2" * | grep info | grep sw_vers
> database/postgresql90.info: if [[ $(sw_vers -productVersion | cut -d.
> -f1-2) > 10.6 ]]; then
> database/postgresql91.info: if [[ $(sw_vers -productVersion | cut -d.
> -f1-2) > 10.6 ]]; then
> database/postgresql92.info: if [[ $(sw_vers -productVersion | cut -d.
> -f1-2) > 10.6 ]]; then
> database/postgresql93.info: if [[ $(sw_vers -productVersion | cut -d.
> -f1-2) > 10.6 ]]; then
> graphics/glew.info: if [[ $(sw_vers -productVersion | cut -d. -f1-2) >
> 10.6 ]]; then
> graphics/inkscape.info: if [[ $(sw_vers -productVersion | cut -d.
> -f1-2) > 10.8 ]]; then
> languages/lua51.info: if [ `/usr/bin/sw_vers -productVersion | cut
> -d'.' -f1-2` == 10.3 ]; then
> languages/lua51.info: if [ `/usr/bin/sw_vers -productVersion | cut
> -d'.' -f1-2` == 10.3 ]; then
> libs/gmm.info: case `sw_vers -productVersion | cut -d. -f1-2` in
> libs/jicmp.info: if [[ $(sw_vers -productVersion | cut -d. -f1-2) >
> 10.6 ]]; then
> libs/jicmp6.info: if [[ $(sw_vers -productVersion | cut -d. -f1-2) >
> 10.6 ]]; then
> libs/libxine1.info: if [[ $(sw_vers -productVersion | cut -d. -f1-2) =
> 10.6 ]]; then
> libs/osxfuse.info:osxversion=`sw_vers -productVersion | cut -d. -f1-2`
> libs/qt4-base-x11.info: if [[ $(sw_vers -productVersion | cut -d.
> -f1-2) > 10.6 ]]; then
> sci/gdl.info:  if [[ $(sw_vers -productVersion | cut -d. -f1-2) > 10.8 ]]; 
> then
> sci/pywavelets-py.info: export PYTHONPATH=%b/build/lib.macosx-`sw_vers
> -productVersion | cut -d. -f1-2`-%m-%type_raw[python]:$PYTHONPATH
> sound/jack.info: if [[ $(sw_vers -productVersion | cut -d. -f1-2) >
> 10.7 ]]; then
> web/linkchecker.info: if [[ $(sw_vers -productVersion | cut -d. -f1-2)
>> 10.8 ]]; then
>
> and perhaps more which aren't being captured by that regex.
>               Jack

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
_______________________________________________
Fink-devel mailing list
Fink-devel@lists.sourceforge.net
List archive:
http://news.gmane.org/gmane.os.apple.fink.devel
Subscription management:
https://lists.sourceforge.net/lists/listinfo/fink-devel

Reply via email to