[SciPy-User] Installation of SciPy 0.8.0 for Python 2.7 on MacOS 10.6

Hans-Martin v. Gaudecker hmgaudecker@gmail....
Fri Sep 24 08:56:45 CDT 2010


Hi, 

I am trying to compile SciPy for use with python.org Python 2.7 on Snow Leopard, but I can't seem to get the architectures to work together correctly (examples all use numscons, the install didn't work with the standard procedure, either). Same behaviour on Core2 Duo MacBook Pro and a Mac Pro with Quad-Core Xeon.

Setting the flags to 64-bit as described on the SciPy website leads to the build to break (F77 BLAS not found). The build runs through if I leave them out, but then many tests fail with [...] no suitable image found. Did find [...]  mach-o, but wrong architecture. 

I am lost -- any help would be greatly appreciated. More details below.

Best wishes,
Hans-Martin


gfortran is 4.2.3 for SL from r.resarch.att.com:

$ gfortran -v
Using built-in specs.
Target: i686-apple-darwin8
Configured with: /Builds/unix/gcc/gcc-4.2/configure --prefix=/usr/local --mandir=/share/man --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --build=i686-apple-darwin8 --host=i686-apple-darwin8 --target=i686-apple-darwin8 --enable-languages=fortran
Thread model: posix
gcc version 4.2.3


Error for: sudo LDFLAGS="-arch x86_64" FFLAGS="-arch x86_64" python setupscons.py scons --jobs=4 install

Mkdir("build/scons/scipy/integrate")
Checking if gfortran needs dummy main - Failed !
Exception: Could not find F77 BLAS, needed for integrate package:
  File "~/Downloads/scipy-0.8.0/scipy/integrate/SConstruct", line 2:
    GetInitEnvironment(ARGUMENTS).DistutilsSConscript('SConscript')
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/numscons/core/numpyenv.py", line 135:
    build_dir = '$build_dir', src_dir = '$src_dir')
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/numscons/scons-local/scons-local-1.2.0/SCons/Script/SConscript.py", line 553:
    return apply(_SConscript, [self.fs,] + files, subst_kw)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/numscons/scons-local/scons-local-1.2.0/SCons/Script/SConscript.py", line 262:
    exec _file_ in call_stack[-1].globals
  File "~/Downloads/scipy-0.8.0/build/scons/scipy/integrate/SConscript", line 15:
    raise Exception("Could not find F77 BLAS, needed for integrate package")
error: Error while executing scons command. See above for more information.
If you think it is a problem in numscons, you can also try executing the scons
command with --log-level option for more detailed output of what numscons is
doing, for example --log-level=0; the lowest the level is, the more detailed
the output it.


Typical test output after "sudo python setupscons.py scons --jobs=4 install" seemed to work fine: 

======================================================================
ERROR: Failure: ImportError (dlopen(/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/scipy/cluster/_hierarchy_wrap.so, 2): no suitable image found.  Did find:
	/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/scipy/cluster/_hierarchy_wrap.so: mach-o, but wrong architecture)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose-0.11.4-py2.7.egg/nose/loader.py", line 382, in loadTestsFromName
    addr.filename, addr.module)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose-0.11.4-py2.7.egg/nose/importer.py", line 39, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose-0.11.4-py2.7.egg/nose/importer.py", line 86, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/scipy/cluster/__init__.py", line 9, in <module>
    import vq, hierarchy
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/scipy/cluster/hierarchy.py", line 199, in <module>
    import _hierarchy_wrap
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/scipy/cluster/_hierarchy_wrap.so, 2): no suitable image found.  Did find:
	/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/scipy/cluster/_hierarchy_wrap.so: mach-o, but wrong architecture



More information about the SciPy-User mailing list