Closed gijzelaerr closed 10 years ago
Original comment thread migrated from bugzilla
We're trying to build MeqTrees from source on Ubuntu 10.04 which already has numpy 1.5.1 installed. Griffin has existing scripts which make use of this and he doesn't want to downgrade. Does MeqTrees demand an earlier version of numpy? I notice the version of numpy on 10.04 machines which are happy to re-build MeqTrees is 1.3.0.
I should also point out that this machine is a Mac, but Ubuntu 10.04 is installed natively.
Here's the error message from the build:
[ 4%] Built target timbase [ 16%] Built target dmi [ 25%] Built target octopussy [ 26%] Building CXX object OCTOPython/CMakeFiles/octopython.dir/src/DataConv.cc.o In file included from /usr/include/python2.6/numpy/ndarrayobject.h:18, from /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:34: /usr/include/python2.6/numpy/numpyconfig.h:4:26: error: _numpyconfig.h: No such file or directory In file included from /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:34: /usr/include/python2.6/numpy/ndarrayobject.h:1036:40: error: _neighborhood_iterator_imp.h: No such file or directory In file included from /usr/include/python2.6/numpy/ndarrayobject.h:68, from /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:34: /usr/include/python2.6/numpy/npy_common.h:840: error: ‘npy_int64’ does not name a type /usr/include/python2.6/numpy/npy_common.h:841: error: ‘npy_int64’ does not name a type In file included from /usr/include/python2.6/numpy/ndarrayobject.h:1238, from /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:34: /usr/include/python2.6/numpy/multiarray_api.h: In function ‘int _import_array()’: /usr/include/python2.6/numpy/__multiarray_api.h:1202: error: ‘NPY_ABI_VERSION’ was not declared in this scope /usr/include/python2.6/numpy/multiarray_api.h:1208: error: ‘NPY_APIVERSION’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc: In function ‘int OctoPython::pyToRecord(DMI::CountedRefDMI::Record&, PyObject)’: /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:208: warning: deprecated conversion from string constant to ‘char_’ /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc: In function ‘DMI::TypeId OctoPython::numarrayToTypeId(int)’: /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:276: error: ‘NPY_INT16’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:277: error: ‘NPY_INT32’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:278: error: ‘NPY_FLOAT32’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:279: error: ‘NPY_FLOAT64’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:280: error: ‘NPY_COMPLEX64’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:281: error: ‘NPY_COMPLEX128’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc: In function ‘int OctoPython::typeIdToNumarray(DMI::TypeId)’: /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:293: error: ‘NPY_INT16’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:294: error: ‘NPY_INT32’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:295: error: ‘NPY_FLOAT32’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:296: error: ‘NPY_FLOAT64’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:297: error: ‘NPY_COMPLEX64’ was not declared in this scope /home/griffin/meqtrees/trunk/Timba/OCTOPython/src/DataConv.cc:298: error: ‘NPY_COMPLEX128’ was not declared in this scope make[2]: * [OCTOPython/CMakeFiles/octopython.dir/src/DataConv.cc.o] Error 1 make[1]: * [OCTOPython/CMakeFiles/octopython.dir/all] Error 2 make: *\ [all] Error 2
1.5.1 is installed on ubuntu 11.04 and works just fine.
Packages required on this platform are: sudo apt-get --force-yes -y -qq install python-pyfits astLib python-qt4-dev python-qt4 casarest casacore liblapack-dev python-qwt5-qt4 blitz-mpp libqdbm14 libqdbm-dev pyrap libfftw3-dev libcfitsio3-dev casacore-measures g++ python2.6 python-numpy libqt4-dev libqt4-gui wcslib cmake python-dev fakeroot dpkg-dev
make VERBOSE=1 might give more clues.
Actually 11.04 uses python 2.7 not python 2.6
you can override this with cmake and the variable:
cmake -DPYTHON_NUMPY_INCLUDE_DIR=
Theres into on finding out these variable names in the README_build.txt file.
Yeah, it looks like this is not a MeqTrees problem per se, but rather an incomplete installation of numpy (missing development headers?), or the paths are incorrect so the wrong version is being picked up. How did you install numpy 1.5 on this machine, was it from source?
at 2011-09-07 13:53:48 Ian Heywood reported:
numpy version compatibility