[Pythonmac-SIG] porting a python extension to OS X 10.2

Stephen A. Langer stephen.langer@nist.gov
Mon, 30 Sep 2002 14:19:34 -0400


Hello --

Can someone point me to a summary of how to compile and link a Python
extension module, written in C++, under OS X 10.2?  On other Unixes 
(Linux, SGI), we compile with gcc 2.95.x and link with gcc -shared, 
producing a .so file
which Python is happy to load.   gcc 3.1 on OS X doesn't understand -shared.
Do I have to use libtool instead?  When I try to do that, libtool complains
at the end about all sorts of undefined symbols, which should have been
resolved by the list of libraries it was given.

What am I missing?

Many thanks,

       Steve



-- 
-- EMail: stephen.langer@nist.gov                    Phone: (301) 975-5423 --
-- WWW:  http://math.nist.gov/mcsd/Staff/SLanger/    Fax:   (301) 990-4127 --
-- Mail: NIST; 100 Bureau Drive -- Stop 8910; Gaithersburg, Md  20899-8910 --