Oddity with Python25 and Xcode 2.5

John Wilder jwelp1 at gmail.com
Sat Nov 24 17:10:03 PST 2007


I was having a problem with installing python25 (2.5.1_3) where it  
would error on executing libtool with the diagnostic:

ld: for architecture ppc
ld: warning prebinding disabled because of undefined symbols
ld: Undefined symbols:
restFP
saveFP
libtool: internal link edit command failed
make: *** [libpython2.5.dylib] Error 1

I recently upgraded to 10.4.11/Xcode 2.5/gcc4.0.1 from 10.3.9/gcc3.3  
on a g4.  Previously I had been able to install python25 successfully  
on 10.3.9 and was upgrading to the latest version.

I found that I could overcome this two ways:

1. modifiying patch-Makefile.pre.in to have -L/usr/lib/gcc/powerpc- 
apple-darwin8/4.0.1/ -llibgcc
[+		-current_version $(VERSION) -lSystem -lSystemStubs -L/usr/lib/gcc/ 
powerpc-apple-darwin8/4.0.1/ -llibgcc $(LDFLAGS)]..

2. adding a soft link in /usr/lib to /usr/lib/gcc/powerpc-apple- 
darwin8/4.0.1/libgcc.a (ln -s /usr/lib/gcc/powerpc-apple- 
darwin8/4.0.1/libgcc.a libgcc4.a) and then modifying patch- 
Makefile.pre.in to have -lgcc4
[+		-current_version $(VERSION) -lSystem -lSystemStubs -lgcc4 $ 
(LDFLAGS)].

Since I don't have an intel Mac, I can only assume that linking to / 
usr/lib/gcc/i686-apple-darwin8/4.0.1/libgcc.a may help there.

Hope this helps,
John




More information about the macports-users mailing list