]> granicus.if.org Git - python/commitdiff
SF Patch #103188, by Donn Cave: BeOS/ar-fake support for extra
authorGuido van Rossum <guido@python.org>
Fri, 19 Jan 2001 00:31:10 +0000 (00:31 +0000)
committerGuido van Rossum <guido@python.org>
Fri, 19 Jan 2001 00:31:10 +0000 (00:31 +0000)
libraries.

(I have no way to test this, I just trust Donn.)

BeOS/ar-fake

index 4a06e3bbdd741eb0e011b2f4e66a3dfda1d330b4..e7efa7540131dceb64311f97c0ce1759f0845371 100755 (executable)
@@ -46,10 +46,19 @@ d)
 so)
         case $BE_HOST_CPU in
         ppc)
-                mwld -xms -export pragma -nodup -o $1 $library/*
+                #  In case your libpython.a refers to any exotic libraries,
+                #  mwld needs to know that here.  The following hack makes
+                #  a couple of assumptions about Modules/Makefile.  If it
+                #  doesn't work, you may as well add the necessary libraries
+                #  here explicitly instead.
+                extralibs=$(
+                        (cd Modules; make -f Makefile -n link) |
+                        sed -n 's/.*\.so \(.*\) -o python.*/\1/p'
+                )
+                mwld -xms -export pragma -nodup -o $1 $library/* $extralibs
                 ;;
         x86)
-                gcc -nostart -Wl,-soname=$(basename $1) -o $1 $library/*
+                ld -shared -soname $(basename $1) -o $1 $library/*
                 ;;
         esac
         status=$?