summaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorRonald Oussoren <ronaldoussoren@mac.com>2010-02-07 19:56:39 (GMT)
committerRonald Oussoren <ronaldoussoren@mac.com>2010-02-07 19:56:39 (GMT)
commit755740f3ea9c5005d16a80c07e7fc26e45f11aa1 (patch)
tree5c764709032b00db8244cde4a358025f61ef5751 /configure.in
parenta5336b60007476389cb3102b9c020bc78c3fca76 (diff)
downloadcpython-755740f3ea9c5005d16a80c07e7fc26e45f11aa1.zip
cpython-755740f3ea9c5005d16a80c07e7fc26e45f11aa1.tar.gz
cpython-755740f3ea9c5005d16a80c07e7fc26e45f11aa1.tar.bz2
Forward port a number of OSX bugfixes from the trunk to 3.2
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in30
1 files changed, 29 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index 58ceea6..a0ca8d5 100644
--- a/configure.in
+++ b/configure.in
@@ -898,6 +898,34 @@ yes)
ARCH_RUN_32BIT=""
LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386"
+ # You have to use different flags on various versions of
+ # OSX to extract PPC code from an universal binary, basically
+ # '-arch ppc' on OSX 10.4 and '-arch ppc7400' on anything
+ # newer.
+ # Because '-arch pp7400' works on OSX 10.5 or higher this
+ # test is only present in the '32-bit' branch, all other
+ # branches require OSX 10.5 to compile.
+
+ AC_MSG_CHECKING(lipo flag for extracting ppc code)
+ FN="test.$$"
+ cat >${FN}.c <<-EOF
+ int main() { return 0; }
+EOF
+ ${CC} ${CFLAGS} -arch ppc -arch i386 -o ${FN} ${FN}.c -isysroot ${UNIVERSALSDK}
+ if test $? != 0 ; then
+ rm ${FN} ${FN}.c
+ AC_MSG_RESULT([failed, assumee -extract ppc7400])
+ else
+ lipo "${FN}" -extract ppc7400 -output "${FN}.out" 2>/dev/null
+ if test $? != 0 ; then
+ LIPO_32BIT_FLAGS="-extract ppc -extract i386"
+ AC_MSG_RESULT("'-extract ppc'")
+ else
+ AC_MSG_RESULT("'-extract ppc7400'")
+ fi
+ rm -f ${FN} ${FN}.c ${FN}.out
+ fi
+
elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then
UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64"
LIPO_32BIT_FLAGS=""
@@ -1251,7 +1279,7 @@ sys/param.h sys/poll.h sys/select.h sys/socket.h sys/statvfs.h sys/stat.h \
sys/termio.h sys/time.h \
sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \
sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \
-bluetooth/bluetooth.h linux/tipc.h)
+bluetooth/bluetooth.h linux/tipc.h spawn.h util.h)
AC_HEADER_DIRENT
AC_HEADER_MAJOR