diff options
author | Ronald Oussoren <ronaldoussoren@mac.com> | 2010-04-18 18:21:03 (GMT) |
---|---|---|
committer | Ronald Oussoren <ronaldoussoren@mac.com> | 2010-04-18 18:21:03 (GMT) |
commit | e3eaf3153f126f9086a29d9bb93ccafdc3210f54 (patch) | |
tree | ce67832cd87f299ff92f331261eac5eb813d8afc /configure.in | |
parent | 7fd72820bcefe9ccfc6fd0204e59da7d6b6126ea (diff) | |
download | cpython-e3eaf3153f126f9086a29d9bb93ccafdc3210f54.zip cpython-e3eaf3153f126f9086a29d9bb93ccafdc3210f54.tar.gz cpython-e3eaf3153f126f9086a29d9bb93ccafdc3210f54.tar.bz2 |
Merged revisions 80187 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r80187 | ronald.oussoren | 2010-04-18 19:59:37 +0200 (Sun, 18 Apr 2010) | 6 lines
Add the OSX universal binary related options
to CFLAGS instead of BASECFLAGS.
This fixes issue 8366 and is needed due to
changes introduced in the fix for issue 1628484.
........
Also: force usage of gcc-4.0 when building using the 10.4 SDK,
this is needed to avoid compile errors when building on OSX 10.6
(and is already in the trunk)
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/configure.in b/configure.in index fcea443..0413533 100644 --- a/configure.in +++ b/configure.in @@ -953,6 +953,22 @@ yes) # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd # used to be here, but non-Apple gcc doesn't accept them. + if test "${CC}" = gcc + then + AC_MSG_CHECKING(which compiler should be used) + case "${UNIVERSALSDK}" in + */MacOSX10.4u.sdk) + # Build using 10.4 SDK, force usage of gcc when the + # compiler is gcc, otherwise the user will get very + # confusing error messages when building on OSX 10.6 + CC=gcc-4.0 + CPP=cpp-4.0 + ;; + esac + AC_MSG_RESULT($CC) + fi + + if test "${enable_universalsdk}"; then UNIVERSAL_ARCH_FLAGS="" if test "$UNIVERSAL_ARCHS" = "32-bit" ; then @@ -993,10 +1009,11 @@ yes) fi - BASECFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${BASECFLAGS}" - 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}" + CFLAGS="${UNIVERSAL_ARCH_FLAGS} ${CFLAGS}" + if test "${UNIVERSALSDK}" != "/" + then + CFLAGS="-isysroot ${UNIVERSALSDK} ${CFLAGS}" + CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" fi fi |