]> granicus.if.org Git - python/commitdiff
#3381 fix framework builds on 10.4
authorBenjamin Peterson <benjamin@python.org>
Thu, 17 Jul 2008 15:59:24 +0000 (15:59 +0000)
committerBenjamin Peterson <benjamin@python.org>
Thu, 17 Jul 2008 15:59:24 +0000 (15:59 +0000)
configure
configure.in

index 2ab958847704228175044978b612130d7fc8a81a..0e028ff2329835ff3e4fedc19e4f619f9e2e577f 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Revision: 64567 .
+# From configure.in Revision: 65033 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.61 for python 2.6.
 #
@@ -4643,6 +4643,8 @@ echo "${ECHO_T}$ac_cv_no_strict_aliasing_ok" >&6; }
        Darwin*)
            # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
            # used to be here, but non-Apple gcc doesn't accept them.
+
+
            if test "${enable_universalsdk}"; then
                UNIVERSAL_ARCH_FLAGS=""
                if test "$UNIVERSAL_ARCHS" = "32-bit" ; then
@@ -4665,8 +4667,33 @@ echo "$as_me: error: proper usage is --with-universalarch=32-bit|64-bit|all" >&2
 
 
                BASECFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${BASECFLAGS}"
-               CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
+               tgt=`sw_vers -productVersion | sed 's/\(10\.0-9*\).*/\1/'`
+               if test "${UNIVERSALSDK}" != "/" -a "${tgt}" '>' '10.4' ; then
+                       CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
+               fi
+           fi
+
+           # Calculate the right deployment target for this build.
+           #
+           cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
+           if test ${cur_target} '>' 10.2; then
+                   cur_target=10.3
            fi
+           if test "${UNIVERSAL_ARCHS}" = "all"; then
+                   # Ensure that the default platform for a 4-way
+                   # universal build is OSX 10.5, that's the first
+                   # OS release where 4-way builds make sense.
+                   cur_target='10.5'
+           fi
+           CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
+
+           # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the
+           # environment with a value that is the same as what we'll use
+           # in the Makefile to ensure that we'll get the same compiler
+           # environment during configure and build time.
+           MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
+           export MACOSX_DEPLOYMENT_TARGET
+           EXPORT_MACOSX_DEPLOYMENT_TARGET=''
 
            ;;
        OSF*)
@@ -13034,26 +13061,7 @@ then
        Darwin/*)
                # Use -undefined dynamic_lookup whenever possible (10.3 and later).
                # This allows an extension to be used in any Python
-               cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
-               if test ${cur_target} '>' 10.2; then
-                       cur_target=10.3
-               fi
-               if test "${UNIVERSAL_ARCHS}" = "all"; then
-                       # Ensure that the default platform for a 4-way
-                       # universal build is OSX 10.5, that's the first
-                       # OS release where 4-way builds make sense.
-                       cur_target='10.5'
-               fi
-               CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
-
-               # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the
-               # environment with a value that is the same as what we'll use
-               # in the Makefile to ensure that we'll get the same compiler
-               # environment during configure and build time.
-               MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
-               export MACOSX_DEPLOYMENT_TARGET
 
-               EXPORT_MACOSX_DEPLOYMENT_TARGET=''
                if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2
                then
                        if test "${enable_universalsdk}"; then
index 7941f2dd742d02c216fccf5240cef2b818345c9a..67d7f969a11da7ebea8c0b9f11d32c3055839988 100644 (file)
@@ -903,6 +903,8 @@ yes)
        Darwin*)
            # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
            # used to be here, but non-Apple gcc doesn't accept them.
+
+
            if test "${enable_universalsdk}"; then
                UNIVERSAL_ARCH_FLAGS=""
                if test "$UNIVERSAL_ARCHS" = "32-bit" ; then
@@ -923,9 +925,34 @@ yes)
 
 
                BASECFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${BASECFLAGS}"
-               CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
+               tgt=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
+               if test "${UNIVERSALSDK}" != "/" -a "${tgt}" '>' '10.4' ; then
+                       CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
+               fi
            fi
 
+           # Calculate the right deployment target for this build.
+           #
+           cur_target=`sw_vers -productVersion | sed 's/\(10\.[[0-9]]*\).*/\1/'`
+           if test ${cur_target} '>' 10.2; then
+                   cur_target=10.3
+           fi
+           if test "${UNIVERSAL_ARCHS}" = "all"; then
+                   # Ensure that the default platform for a 4-way
+                   # universal build is OSX 10.5, that's the first
+                   # OS release where 4-way builds make sense.
+                   cur_target='10.5'
+           fi
+           CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
+           
+           # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the 
+           # environment with a value that is the same as what we'll use
+           # in the Makefile to ensure that we'll get the same compiler
+           # environment during configure and build time.
+           MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
+           export MACOSX_DEPLOYMENT_TARGET
+           EXPORT_MACOSX_DEPLOYMENT_TARGET=''
+
            ;;
        OSF*)
            BASECFLAGS="$BASECFLAGS -mieee"
@@ -1624,26 +1651,7 @@ then
        Darwin/*)
                # Use -undefined dynamic_lookup whenever possible (10.3 and later).
                # This allows an extension to be used in any Python
-               cur_target=`sw_vers -productVersion | sed 's/\(10\.[[0-9]]*\).*/\1/'`
-               if test ${cur_target} '>' 10.2; then
-                       cur_target=10.3
-               fi
-               if test "${UNIVERSAL_ARCHS}" = "all"; then
-                       # Ensure that the default platform for a 4-way
-                       # universal build is OSX 10.5, that's the first
-                       # OS release where 4-way builds make sense.
-                       cur_target='10.5'
-               fi
-               CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
-
-               # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the 
-               # environment with a value that is the same as what we'll use
-               # in the Makefile to ensure that we'll get the same compiler
-               # environment during configure and build time.
-               MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
-               export MACOSX_DEPLOYMENT_TARGET
 
-               EXPORT_MACOSX_DEPLOYMENT_TARGET=''
                if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2
                then
                        if test "${enable_universalsdk}"; then