[pymvpa] Error when compiling libsvm-c extension

Yaroslav Halchenko debian at onerussian.com
Mon Mar 19 16:26:25 UTC 2012


I guess you are just enjoying what was recently reported, troubleshooted
and answered by Loris Bennett:

http://lists.alioth.debian.org/pipermail/pkg-exppsy-pymvpa/2012q1/002043.html

,---
| I found the answer myself.  On Scientific Linux (SL) and presumably
| other RedHat-based systems, the 'numpy' package does not contain certain
| submodules, such as 'distutils', which are present in the Debian 'numpy'
| package.  On SL I had to install 'numpy-f2py', which I assumed just had
| something to do with converting Fortran to Python.  Apparently not.
`---


On Mon, 19 Mar 2012, Gilles de Hollander wrote:

>    Hi there,
>    I've been struggling with installing PyMVPA on a Linux server for hours
>    now and I just can't find the problem. When installing using�
>    python setup.py build_ext
>    I get the following error, when building the 'mvpa.clfs.libsvmc._svmc'
>    extension:
>    g++: build/src.linux-x86_64-2.7/mvpa/clfs/libsvmc/svmc_wrap.cpp
>    build/src.linux-x86_64-2.7/mvpa/clfs/libsvmc/svmc_wrap.cpp:3051:31: fatal
>    error: numpy/arrayobject.h: No such file or directory
>    compilation terminated.
>    build/src.linux-x86_64-2.7/mvpa/clfs/libsvmc/svmc_wrap.cpp:3051:31: fatal
>    error: numpy/arrayobject.h: No such file or directory
>    compilation terminated.
>    error: Command "g++ -pthread -fno-strict-aliasing -g -O2 -DNDEBUG
>    -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector
>    -funwind-tables -fasynchronous-unwind-tables -g -fPIC -I/usr/include/numpy
>    -I3rd/libsvm -I/usr/lib64/python2.7/site-packages/numpy/core/include
>    -I/usr/include/python2.7 -c
>    build/src.linux-x86_64-2.7/mvpa/clfs/libsvmc/svmc_wrap.cpp -o
>    build/temp.linux-x86_64-2.7/build/src.linux-x86_64-2.7/mvpa/clfs/libsvmc/svmc_wrap.o"
>    failed with exit status 1
>    I have installed the latest versions of SWIG and NumPy. I can import numpy
>    in python without any problems. It is installed in
>    /usr/lib64/python2.7/site-packages/numpy
>    I have tried copying arrayobjects.h
>    from�/usr/lib64/python2.7/site-packages/numpy/arrayobjects.h�to�/usr/lib64/python2.7/site-packages/numpy/numpy/arrayobjects.h,
>    then the compiler finds it, but I get an even larger list of
>    out-of-scope-errors, starting off with:
>    /usr/lib64/python2.7/site-packages/numpy/core/include/numpy/arrayobject.h:5:2:
>    error: #error You should not include this
>    When using
>    python setup.py build_ext --with-libsvm
>    I get similar errors
>    It would make my life a lot easier if I could run my scripts on this
>    server, so I'm desperate for any tips/help!
>    Thanks in advance,
>    Cheers,
>    Gilles de Hollander
>    Graduate Student University of Amsterdam

> _______________________________________________
> Pkg-ExpPsy-PyMVPA mailing list
> Pkg-ExpPsy-PyMVPA at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-exppsy-pymvpa


-- 
=------------------------------------------------------------------=
Keep in touch                                     www.onerussian.com
Yaroslav Halchenko                 www.ohloh.net/accounts/yarikoptic



More information about the Pkg-ExpPsy-PyMVPA mailing list