[SciPy-User] Error installing scipy

David david@silveregg.co...
Tue Oct 26 20:09:05 CDT 2010


On 10/27/2010 03:52 AM, Di Zou wrote:
> Hi,
>
> I am trying to install scipy 0.8 on Red Hat 5. I have numpy 1.5.1 and
> python 2.6.
> When I do 'python setup.py install
> --prefix=/share/dizou/local/scipy-0.8' I get this error:
> File "setup.py", line 160, in <module>
> setup_package()
> File "setup.py", line 127, in setup_package
> from numpy.distutils.core import setup
> File
> "/share/dizou/local/numpy-1.5.1/lib/python2.6/site-packages/numpy/distutils/__init__.py",
> line 7, in <module>
> import ccompiler
> File
> "/share/dizou/local/numpy-1.5.1/lib/python2.6/site-packages/numpy/distutils/ccompiler.py",
> line 7, in <module>
> from distutils.ccompiler import *
> File
> "/share/dizou/local/numpy-1.5.1/lib/python2.6/site-packages/numpy/distutils/__init__.py",
> line 7, in <module>
> import ccompiler
> File
> "/share/dizou/local/numpy-1.5.1/lib/python2.6/site-packages/numpy/distutils/ccompiler.py",
> line 8, in <module>
> from distutils import ccompiler
> ImportError: cannot import name ccompiler
> When I do 'which gcc' at the terminal window I get: /usr/bin/gcc
> How do I fix this?

This error is really strange. Could you quickly try this from your 
terminal ?

python -c "from distutils import ccompiler"

If this does not work, there is something wrong with your setup (what is 
your PYTHONPATH ?), or your python install is seriously broken (but you 
would not have been able to install numpy that way, so I suspect the 
configuration problem to be more likely),

cheers,

David


More information about the SciPy-User mailing list