[gdal-dev] GDAL / Python and PPC

Sean Gillies sgillies at frii.com
Sat Jan 5 21:01:58 EST 2008


Brian Hamlin wrote:
> Hi all-
> 
>   over the winter break, I decided I would get into the Python swing of
> things.. I loaded numpy into my OS X Framework Python 2.5.1. The problem
> was, numpy wanted to build both i386 and PPC architectures. I jiggled
> and rattled - I honestly dont remember exactly, and built just the PPC
> architecture. This is OS 10.4.10. All the tests run fine, and import
> numpy is happy in the interactive shell.
> 
> * I have numpy in python. * import numpy works fine without any GDAL
> anything ***
> 
>   Now, moving to GDAL, I configured --with-python, and make. The build
> gets to SWIG, which gets to Python, which sees Numpy, and.. issues the
> commands in a striking yellow text to build both PPC and i386 arch. This
> fails, and the make comes to a halt. Oh yes, it is in the make install,
> actually. Make itself succeeds.
> 
> 
> UPDATE: I just reinstalled (after a full backup) the OSX Dev System for
> 10.3 and 10.4 Universal. then built GDAL. Same result, on install,
> python bindings hit numpy, then try to build numpy and fail to link on
> i386 everything. I went into setup.py and added extra_compile_args = [
> '-g', '-arch', 'ppc' ]
> that appears in the build output, but a line later than the fatal C
> compiler: 'osgeo.gdal' -arch ppc -arch i386
> 
> no python...
> 
>   -Brian

Brian,

You could also take the modern Python route: simply build the library
--without-python, get the setuptools module by downloading and executing

http://peak.telecommunity.com/dist/ez_setup.py

and then execute:

  $ easy_install GDAL

Howard has put a ton of work into it. Should just plain work and build
numpy for you as well.

Cheers,
Sean


More information about the gdal-dev mailing list