summaryrefslogtreecommitdiff
path: root/Python/mactoolboxglue.c
diff options
context:
space:
mode:
authorRonald Oussoren <ronaldoussoren@mac.com>2008-06-05 12:58:24 +0000
committerRonald Oussoren <ronaldoussoren@mac.com>2008-06-05 12:58:24 +0000
commit5640ce2f1edc0148ee14fd3daeb7ac700700bb71 (patch)
tree9bc8b41710d3a86ccbb579a0209928d787386b69 /Python/mactoolboxglue.c
parent80af6da7489c3b28e0a46c73849da34273972e3b (diff)
downloadcpython-git-5640ce2f1edc0148ee14fd3daeb7ac700700bb71.tar.gz
MacOS X: Enable 4-way universal builds
This patch adds a new configure argument on OSX: --with-universal-archs=[32-bit|64-bit|all] When used with the --enable-universalsdk option this controls which CPU architectures are includes in the framework. The default is 32-bit, meaning i386 and ppc. The most useful alternative is 'all', which includes all 4 CPU architectures supported by MacOS X (i386, ppc, x86_64 and ppc64). This includes limited support for the Carbon bindings in 64-bit mode as well, limited because (a) I haven't done extensive testing and (b) a large portion of the Carbon API's aren't available in 64-bit mode anyway. I've also duplicated a feature of Apple's build of python: setting the environment variable 'ARCHFLAGS' controls the '-arch' flags used for building extensions using distutils.
Diffstat (limited to 'Python/mactoolboxglue.c')
-rw-r--r--Python/mactoolboxglue.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Python/mactoolboxglue.c b/Python/mactoolboxglue.c
index e96bb645d2..19ec4cf476 100644
--- a/Python/mactoolboxglue.c
+++ b/Python/mactoolboxglue.c
@@ -106,6 +106,7 @@ PyMac_Error(OSErr err)
}
+#ifndef __LP64__
OSErr
PyMac_GetFullPathname(FSSpec *fss, char *path, int len)
{
@@ -153,6 +154,7 @@ PyMac_GetFullPathname(FSSpec *fss, char *path, int len)
Py_XDECREF(fs);
return err;
}
+#endif /* !__LP64__ */
/* Convert a 4-char string object argument to an OSType value */
int
@@ -417,6 +419,7 @@ GLUE_CONVERT(RGBColor, QdRGB_Convert, "Carbon.Qd")
GLUE_NEW(GWorldPtr, GWorldObj_New, "Carbon.Qdoffs")
GLUE_CONVERT(GWorldPtr, GWorldObj_Convert, "Carbon.Qdoffs")
+#ifndef __LP64__
GLUE_NEW(Track, TrackObj_New, "Carbon.Qt")
GLUE_CONVERT(Track, TrackObj_Convert, "Carbon.Qt")
GLUE_NEW(Movie, MovieObj_New, "Carbon.Qt")
@@ -429,6 +432,7 @@ GLUE_NEW(UserData, UserDataObj_New, "Carbon.Qt")
GLUE_CONVERT(UserData, UserDataObj_Convert, "Carbon.Qt")
GLUE_NEW(Media, MediaObj_New, "Carbon.Qt")
GLUE_CONVERT(Media, MediaObj_Convert, "Carbon.Qt")
+#endif /* !__LP64__ */
GLUE_NEW(Handle, ResObj_New, "Carbon.Res")
GLUE_CONVERT(Handle, ResObj_Convert, "Carbon.Res")