[Pythonmac-SIG] Tiger hand rolled Python 2.4.1: libxml2 oddities

Gary Poster gary at modernsongs.com
Thu May 5 22:31:02 CEST 2005


On May 5, 2005, at 2:31 PM, Bob Ippolito wrote:

>
> On May 5, 2005, at 2:20 PM, Bob Ippolito wrote:
>> It sounds like libxml2 (or the Python extension) uses the linker
>> option flat_namespace .. that's bad.  -flat_namespace has been
>> deprecated since 10.2 (maybe earlier) and shouldn't be used for
>> anything.  I can't help you though, I don't use libxml2 so I don't
>> know the specifics of why its build/link procedure is broken.
>>
>
> More specifically, after looking again, "libxml2mod.so" isn't  
> explicitly linking to libxml2 (and may also be using the deprecated  
> -flat_namespace)..  Somewhere in your "one command" it's importing  
> something that does explicitly link to libxml2, but your "another  
> command" does not have that side-effect that band-aids the fact  
> that "libxml2mod.so" is linked incorrectly.  The solution to this  
> specific problem is to fix whatever builds "libxml2mod.so" so that  
> it links against libxml2 (-lxml2, or adding it to the distutils  
> library list, etc.).. but I have a feeling that's not the ONLY  
> thing wrong with it.
>
> It "smells" like one of those horribly broken Python extensions  
> that uses autoconf instead of distutils.

Your analysis seems to have been dead on for all counts.  I have a  
workaround for now--import a 'good' libxml2 before whatever offending  
badly linked version comes into the sys.modules--and I really need to  
actually get some work done.  I'll dig into it a bit more when I can  
and report back if I find anything useful.

Thank you!

Gary


More information about the Pythonmac-SIG mailing list