[Image-SIG] PIL and target processors and OSX, oh-my!

Christopher Barker Chris.Barker at noaa.gov
Thu May 15 19:23:26 CEST 2008


Jon McKamey wrote:
> I’m trying to get PIL and mod_python to run on apache2 on a Mac running 
> OSX 10.5  To give some background,  httpd is build with 4 target 
> processors, so everything loaded by it (mod_python, PIL, etc) has to be 
> built to handle all 4 target processors.  Including all PIL and it’s 
> libraries. I am to the point where PIL has been rebuilt for the 4 target 
> processors.   If I run otool on it, I get the list of modules it loads, 
> and not all of them are built for the 4 processors, some of which appear 
> to be OS built-in libraries.
> 
> So, the point I am stuck at:  It’s not clear to me how and what to do to 
> rebuild those modules, and it’s not clear to me if it’s even safe to 
> rebuild and replace those modules with 4 processor versions of the 
> files.

I wouldn't. Also, I'm a bit confused. The Apple-supplied built-in ones 
should be dynamic libs, and I thought those only had to be built for the 
processor you are running on.

Which libs are you having issues with?

Anyway, I wouldn't replace ANY system libs. If the system ones won't 
work for you, you'll probably need to build your own versions of them, 
install them elsewhere, and make sure PIL links to those.

 > Macports?

Last I heard MacPorts and Fink don't do any multi-processor building. 
Which leaves you with:

> Download the source and go?

The problem there is that many (most) libs don't build Universal out of 
the box, so you need o go in and hack the MakeFiles. I've only done dual 
mode builds (PPC and Intel, 32bit), but I imagine it's a similar deal. 
One trick is going to be if Configure sets anything about 32 vs. 64 
bits, then you may run into issues. I think most of the endian issues 
have been addressed in the major libraries.


I'd try this question on the pythonmac list -- it's really more a Mac 
issue than a PIL one.

Good luck!

-Chris

-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov



More information about the Image-SIG mailing list