[Pythonmac-SIG] compiling PIL on OSX10.5
DavidW
vip at avatar.com.au
Thu Feb 28 12:49:28 CET 2008
Hi Ronald, Thanks for replying.
On 28/02/2008, at 9:18 PM, Ronald Oussoren wrote:
> Which version of python are you using? The Python.org installer
> builds extensions using the 10.4 SDK to ensure that extensions will
> actually run on that platform.
>
Python 2.4.3 (#1, Mar 30 2006, 11:02:16)
[GCC 4.0.1 (Apple Computer, Inc. build 5250)] on darwin
> BTW. What I don't undestand is why building PIL tries to link
> libcrypto.
>
> Do you have a libcrypto dylib in /usr/local/lib? If so, what is the
> output of the file command on that? (file /usr/local/lib/
> libcrypto*). It seems that the libcrypto that's linked into the
> extension is PPC-only, while distutils tries to build a 32-bit
> universal binary.
>
you guessed it!
Macintosh:SDKs drw$ file /usr/local/lib/libcr*
/usr/local/lib/libcrypto.0.9.7.dylib: Mach-O dynamically linked shared
library ppc
Now I'm wondering what to do. This is an intel macbook. upgrade from
OSX 10.4.11 to 10.5 was ?ok? but things got stuffed up when trying to
implement the 10.5.1 upgrade. Recommendation?
[aside: I've got about 30 apl/libraries in the and am reluctant to
move to python 2.5 at this moment if I have to rebuild all the dylibs.
If I have to then I guess I'll bite the bullet. If I just copy the
python2.4/site-packages directory across is it likely to work?]
ciao,
David
> Ronald
>
> On 28 Feb, 2008, at 6:05, DavidW wrote:
>
>> Hello all,
>>
>> I'm trying to compile the image library PIL 1.1.6, using their
>> setup.py
>> (python 2.4 on OX10.5) and
>> gcc (i686-apple-darwin9-gcc-4.0.1) loader is throwing a build error:
>> -----------
>> building '_imagingtk' extension
>> gcc -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk -
>> g -
>> bundle -undefined dynamic_lookup build/temp.macosx-10.5-fat-2.4/
>> _imagingtk.o build/temp.macosx-10.5-fat-2.4/Tk/tkImaging.o -L/opt/
>> local/lib -L/usr/local/lib -L/Library/Frameworks/Python.framework/
>> Versions/2.4/lib -L/usr/lib -o PIL/_imagingtk.so -framework Tcl -
>> framework Tk
>> ld: in /Developer/SDKs/MacOSX10.4u.sdk/usr/local/lib/libcrypto.
>> 0.9.7.dylib, file is not of required architecture for architecture
>> i386
>> collect2: ld returned 1 exit status
>> -----------
>> which is fair enough, but- why is setup.py looking for /Developer/
>> SDKs/
>> MacOSX10.4u.sdk?
>> even though MacOSX10.5.sdk is also at Developer/SDKs/
>>
>> Is there any reason to keep MacOSX10.4.sdk hanging around?
>> I moved it out of the way and setup.py puts this together for
>> compilation:
>> -----------
>> building '_imagingmath' extension
>> gcc -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk -
>> fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-
>> madd -
>> fno-common -dynamic -DNDEBUG -g -I/System/Library/Frameworks/
>> Tcl.framework/Headers -I/System/Library/Frameworks/Tk.framework/
>> Headers -IlibImaging -I/opt/local/include -I/Library/Frameworks/
>> Python.framework/Versions/2.4/include -I/usr/local/include -I/usr/
>> include -I/Library/Frameworks/Python.framework/Versions/2.4/include/
>> python2.4 -c _imagingmath.c -o build/temp.macosx-10.5-fat-2.4/
>> _imagingmath.o
>> -----------
>> i.e it still want to reference /Developer/SDKs/MacOSX10.4u.sdk
>>
>> Any clues?
>> (golly, I hope this is the right list for this ! :-)
>>
>> thanks,
>> David
>>
>> ________________________________________________
>> David Worrall.
>> - Experimental Polymedia: www.avatar.com.au
>> - Education for Financial Independence: www.mindthemarkets.com.au
>> Australian research affiliations:
>> - Capital Markets Cooperative Research Centre: www.cmcrc.com
>> - Sonic Communications Research Group: creative.canberra.edu.au/scrg
>>
>>
>>
>> _______________________________________________
>> Pythonmac-SIG maillist - Pythonmac-SIG at python.org
>> http://mail.python.org/mailman/listinfo/pythonmac-sig
>
More information about the Pythonmac-SIG
mailing list