]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
backport my checkin of
authorMichael W. Hudson <mwh@python.net>
Thu, 7 Mar 2002 10:04:49 +0000 (10:04 +0000)
committerMichael W. Hudson <mwh@python.net>
Thu, 7 Mar 2002 10:04:49 +0000 (10:04 +0000)
    revision 1.84 of setup.py
    revision 1.293 of configure.in

Apply Jack's patch attached to

[ 508779 ] Disable flat namespace on MacOS X

I presume you wanted this on the trunk too, Jack?

2.2.1 candidate.

configure.in
setup.py

index 385ff57eaaf330d32705a35557db53d3f1fefcb6..39b55f2c98194a0b20536828e1b490b3e5b1eb16 100644 (file)
@@ -793,8 +793,9 @@ then
                        # Link against the framework. All externals should be defined.
                        LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
                else
-                       # No framework. Ignore undefined symbols, assuming they come from Python
-                       LDSHARED="$LDSHARED -flat_namespace -undefined suppress"
+                       # No framework, use the Python app as bundle-loader
+                       BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
+                       LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/$(PYTHON)'
                fi ;;
        Linux*) LDSHARED="gcc -shared";;
        dgux*) LDSHARED="ld -G";;
index 29b7b4a5ea7bae2986b69354efc93763f33d8cd5..762bbeeef03b2c741dffbb7648975e3205aa7d67 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -586,7 +586,8 @@ class PyBuildExt(build_ext):
             # available here. This Makefile variable is also what the install
             # procedure triggers on.
             frameworkdir = sysconfig.get_config_var('PYTHONFRAMEWORKDIR')
-            exts.append( Extension('gestalt', ['gestaltmodule.c']) )
+            exts.append( Extension('gestalt', ['gestaltmodule.c'],
+                       extra_link_args=['-framework', 'Carbon']) )
             exts.append( Extension('MacOS', ['macosmodule.c'],
                         extra_link_args=['-framework', 'Carbon']) )
             exts.append( Extension('icglue', ['icgluemodule.c'],
@@ -595,8 +596,10 @@ class PyBuildExt(build_ext):
                                    ['macfsmodule.c',
                                     '../Python/getapplbycreator.c'],
                         extra_link_args=['-framework', 'Carbon']) )
-            exts.append( Extension('_CF', ['cf/_CFmodule.c']) )
-            exts.append( Extension('_Res', ['res/_Resmodule.c']) )
+            exts.append( Extension('_CF', ['cf/_CFmodule.c'],
+                        extra_link_args=['-framework', 'CoreFoundation']) )
+            exts.append( Extension('_Res', ['res/_Resmodule.c'],
+                        extra_link_args=['-framework', 'Carbon']) )
             exts.append( Extension('_Snd', ['snd/_Sndmodule.c'],
                         extra_link_args=['-framework', 'Carbon']) )
             if frameworkdir: