[XML-SIG] [ pyxml-Bugs-605323 ] setup.py build failure on MacOS X

noreply@sourceforge.net noreply@sourceforge.net
Thu, 05 Sep 2002 16:11:47 -0700


Bugs item #605323, was opened at 2002-09-05 16:11
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=106473&aid=605323&group_id=6473

Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: setup.py build failure on MacOS X

Initial Comment:
On MacOS X 10.1.5, Python 2.2, PyXML 0.8.

Build apparently fails for some users with 

[localhost:~/PyXML-0.8] % python setup.py build
running build
running build_py
creating build
creating build/lib.darwin-5.5-Power Macintosh-2.2
creating build/lib.darwin-5.5-Power Macintosh-2.2/_xmlplus
copying xml/__init__.py -> build/lib.darwin-5.5-Power Macintosh-
2.2/_xmlplus

[ tons of stuff deleted]

cc -g -O3 -Wall -Wstrict-prototypes -no-cpp-precomp -
DHAVE_EXPAT_H -DXML_BYTE_ORDER=21 -Iextensions/
expat/lib -I/usr/local/include/python2.2 -c extensions/expat/lib/
xmlrole.c -o build/temp.darwin-5.5-Power Macintosh-2.2/xmlrole.o
cc -g -O3 -Wall -Wstrict-prototypes -no-cpp-precomp -
DHAVE_EXPAT_H -DXML_BYTE_ORDER=21 -Iextensions/
expat/lib -I/usr/local/include/python2.2 -c extensions/expat/lib/
xmltok.c -o build/temp.darwin-5.5-Power Macintosh-2.2/xmltok.o
cc -bundle -flat_namespace -undefined suppress build/
temp.darwin-5.5-Power Macintosh-2.2/pyexpat.o build/
temp.darwin-5.5-Power Macintosh-2.2/xmlparse.o build/
temp.darwin-5.5-Power Macintosh-2.2/xmlrole.o build/temp.darwin-
5.5-Power Macintosh-2.2/xmltok.o -o build/lib.darwin-5.5-Power 
Macintosh-2.2/_xmlplus/parsers/pyexpat.so -flat_namespace
/usr/bin/ld: -undefined: unknown argument: -lbundle1.o
error: command 'cc' failed with exit status 1

Doesn't seem to happen to everyone, but apparently due to -
flat_namespace appearing twice in last cc.  Apparently fixed when 
I alter the line in setup.py

if sys.platform[:6] == "darwin": # Mac OS X
    LDFLAGS.append('-flat_namespace')

to not append '-flat_namespace'.  Might need to check if this is 
already in LDFLAGS?




----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=106473&aid=605323&group_id=6473