[Pythonmac-SIG] _environ

Keith Jackson krjackson at lbl.gov
Mon Aug 11 20:28:51 EDT 2003


Sorry if this has been asked before, but the only refs I found were 
back in 2002. I just built python 2.3 using the mac build instructions, 
so it is built as a framework. I then tried to build some of my 
extension modules and they would fail with an undefined symbol error 
for _environ. nm shows that this is defined in the python executable. 
Looking through the linker man page, I see that since two level 
namespaces are being used it wants to resolve all symbols at static 
link time.

To fix this problem, I added in "-bundle_loader /usr/local/bin/python". 
I think this tells the linker to look in the python executable to find 
symbols. Does anybody know if this is the *right* thing to do? Can I 
safely add this into my python config/Makefile so all extension builds 
do this?
thanks,
--keith




More information about the Pythonmac-SIG mailing list