[SciPy-user] Scipy fails to build in Mac OS X 10.5

Mannucci, Anthony J anthony.j.mannucci@jpl.nasa....
Thu Nov 13 10:22:05 CST 2008


I am trying to build numpy and scipy on Mac OS X 10.5.5. I recently
installed Apple's Developer Tools (3.1.1) and am using gfortran 4.2.3. Gcc
is at version 4.0.1. I installed the latest python (2.6) from the offcial
python site using a binary. I then installed fftw 3.1.2. This appeared to
install (no explicit tests were run). I created three softlinks as suggested
on the site:
http://www.scipy.org/Installing_SciPy/Mac_OS_X

Then I tried numpy. I incorrectly tried to install a binary for numpy with
python 2.5. Not surprisngly, that did not work (numpy not found). I then
grabbed the source for numpy from SourceForge and compiled that, which
seemed to finish. For numpy, I installed like this:

sudo python setup.py build >& build.log
sudo python setup.py install

I then turned to SciPy. I obtained the tarball for version 0.6.0. I unpacked
it and ran the following

python setup.py build_src build_clib --fcompiler=gnu95 build_ext
--fcompiler=gnu95 build >& config.log

This produced lots of error messages, such as:
> mkl_info:
>   libraries mkl,vml,guide not found in
> /Library/Frameworks/Python.framework/Versions/2.6/lib
>   libraries mkl,vml,guide not found in /usr/local/lib
>   libraries mkl,vml,guide not found in /usr/lib
>   NOT AVAILABLE
>
> fftw3_info:
>   libraries fftw3 not found in
> /Library/Frameworks/Python.framework/Versions/2.6/lib
>   FOUND:
>     libraries = ['fftw3']
>     library_dirs = ['/usr/local/lib']
>     define_macros = [('SCIPY_FFTW3_H', None)]
>     include_dirs = ['/usr/local/include']
>
> djbfft_info:
>   NOT AVAILABLE
>
> blas_opt_info:
>   FOUND:
>     extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']
>     define_macros = [('NO_ATLAS_INFO', 3)]
>     extra_compile_args = ['-msse3',
> '-I/System/Library/Frameworks/vecLib.framework/Headers']
>
> lapack_opt_info:
>   FOUND:
>     extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']
>     define_macros = [('NO_ATLAS_INFO', 3)]
>     extra_compile_args = ['-msse3']
>
> non-existing path in 'scipy/linsolve': 'tests'
> umfpack_info:
>   libraries umfpack not found in
> /Library/Frameworks/Python.framework/Versions/2.6/lib
>   libraries umfpack not found in /usr/local/lib
>   libraries umfpack not found in /usr/lib

Etc. Some of the build seemed to go OK, and then I found these errors near
the end:

> building 'scipy.linsolve._zsuperlu' extension
> compiling C sources
> C compiler: gcc -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk
> -fno-strict-aliasing -fno-common -dy
> namic -DNDEBUG -g -O3
>
> compile options: '-DNO_ATLAS_INFO=3 -DUSE_VENDOR_BLAS=1
> -I/Library/Frameworks/Python.framework/Versions/2.6/lib/pyt
> hon2.6/site-packages/numpy/core/include
> -I/Library/Frameworks/Python.framework/Versions/2.6/include/python2.6 -c'
> extra options: '-msse3'
> gcc: scipy/linsolve/_superluobject.c
> In file included from scipy/linsolve/_superluobject.h:8,
>                  from scipy/linsolve/_superluobject.c:5:
> scipy/linsolve/SuperLU/SRC/scomplex.h:60: error: conflicting types for
> '_Py_c_abs'
> /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/complexobj
> ect.h:30: error: previous declaration
>  of '_Py_c_abs' was here
> In file included from scipy/linsolve/_superluobject.h:8,
>                  from scipy/linsolve/_superluobject.c:5:
> scipy/linsolve/SuperLU/SRC/scomplex.h:60: error: conflicting types for
> '_Py_c_abs'
> /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/complexobj
> ect.h:30: error: previous declaration
>  of '_Py_c_abs' was here
> lipo: can't figure out the architecture type of: /var/tmp//ccWenONq.out
> In file included from scipy/linsolve/_superluobject.h:8,
>                  from scipy/linsolve/_superluobject.c:5:
> scipy/linsolve/SuperLU/SRC/scomplex.h:60: error: conflicting types for
> '_Py_c_abs'
> /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/complexobj
> ect.h:30: error: previous declaration
>  of '_Py_c_abs' was here
> In file included from scipy/linsolve/_superluobject.h:8,
>                  from scipy/linsolve/_superluobject.c:5:
> scipy/linsolve/SuperLU/SRC/scomplex.h:60: error: conflicting types for
> '_Py_c_abs'
> /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/complexobj
> ect.h:30: error: previous declaration
>  of '_Py_c_abs' was here
> lipo: can't figure out the architecture type of: /var/tmp//ccWenONq.out
> error: Command "gcc -arch ppc -arch i386 -isysroot
> /Developer/SDKs/MacOSX10.4u.sdk -fno-strict-aliasing -fno-common
>  -dynamic -DNDEBUG -g -O3 -DNO_ATLAS_INFO=3 -DUSE_VENDOR_BLAS=1
> -I/Library/Frameworks/Python.framework/Versions/2.6
> /lib/python2.6/site-packages/numpy/core/include
> -I/Library/Frameworks/Python.framework/Versions/2.6/include/python2
> .6 -c scipy/linsolve/_superluobject.c -o
> build/temp.macosx-10.3-i386-2.6/scipy/linsolve/_superluobject.o -msse3" fa
> iled with exit status 1

Running numpy tests fails as follows:
> Tonys-Mac-2:286:scipy-0.6.0 $ python
> Python 2.6 (trunk:66714:66715M, Oct  1 2008, 18:36:04)
> [GCC 4.0.1 (Apple Computer, Inc. build 5370)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import numpy
>>>> numpy.test('1')
> Running unit tests for numpy
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
> /numpy/testing/nosetester.py", line 240, in test
>     self._show_system_info()
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
> /numpy/testing/nosetester.py", line 151, in _show_system_info
>     nose = import_nose()
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
> /numpy/testing/nosetester.py", line 51, in import_nose
>     raise ImportError(msg)
> ImportError: Need nose >= 0.10.0 for tests - see
> http://somethingaboutorange.com/mrl/projects/nose

I found the nose package and installed it, using easy_install (no direct
download), like this:
$ sudo easy_install nose

Numpy tests continue to fail, as follows:

> Tonys-Mac-2:286:scipy-0.6.0 $ python
> Python 2.6 (trunk:66714:66715M, Oct  1 2008, 18:36:04)
> [GCC 4.0.1 (Apple Computer, Inc. build 5370)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import numpy
>>>> numpy.test('1')
> Running unit tests for numpy
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
> /numpy/testing/nosetester.py", line 240, in test
>     self._show_system_info()
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
> /numpy/testing/nosetester.py", line 151, in _show_system_info
>     nose = import_nose()
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages
> /numpy/testing/nosetester.py", line 51, in import_nose
>     raise ImportError(msg)
> ImportError: Need nose >= 0.10.0 for tests - see
> http://somethingaboutorange.com/mrl/projects/nose

I believe when I did easy_install, version 0.10.4 of nose was used. Any help
is appreciated.

Thank you!

-Tony
--
Tony Mannucci
Supervisor, Ionospheric and Atmospheric Remote Sensing Group
 Mail-Stop 138-308,                     Tel > (818) 354-1699
 Jet Propulsion Laboratory,              Fax > (818) 393-5115
 California Institute of Technology,     Email > Tony.Mannucci@jpl.nasa.gov
 4800 Oak Grove Drive,                   http://genesis.jpl.nasa.gov
 Pasadena, CA 91109




More information about the SciPy-user mailing list