最后我的应用程序在Ubuntu 16.04和17.10上被捕获但是现在我尝试在Ubuntu Core(使用我的覆盆子)上捕捉它,而我的python部分(取决于numpy)在构建时遇到以下问题:
Running setup.py bdist_wheel for numpy ... error
Complete output from command /home/getty23/cavi/cavi-device-snap/parts/cavi-device-sdk/install/usr/bin/python2 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-9foo8C/numpy/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmpewhEJRpip-wheel-:
Running from numpy source directory.
blas_opt_info:
blas_mkl_info:
libraries mkl,vml,guide not found in ['/home/getty23/cavi/cavi-device-snap/parts/cavi-device-sdk/install/usr/lib', '/usr/local/lib', '/usr/lib', '/usr/lib/arm-linux-gnueabihf']
NOT AVAILABLE
... (更多日志here) ...
arm-linux-gnueabihf-gcc: numpy/core/src/multiarray/arrayobject.c
numpy/core/src/multiarray/arrayobject.c:1838:5: error: ‘array_methods’ undeclared here (not in a function)
array_methods, /* tp_methods */
^
numpy/core/src/multiarray/arrayobject.c:1840:5: error: ‘array_getsetlist’ undeclared here (not in a function)
array_getsetlist, /* tp_getset */
^
numpy/core/src/multiarray/arrayobject.c:1838:5: error: ‘array_methods’ undeclared here (not in a function)
array_methods, /* tp_methods */
^
numpy/core/src/multiarray/arrayobject.c:1840:5: error: ‘array_getsetlist’ undeclared here (not in a function)
array_getsetlist, /* tp_getset */
这是使用numpy的应用程序的一部分:
parts:
cavi-device-sdk:
plugin: python
python-version: python2
source: ../cavi-device-sdk
stage-packages:
- liblapack-dev
- libatlas-base-dev
- gfortran
- libatlas-dev
- python-dev
- libc6
- python-numpy
我已经尝试包含不同的库(libblas-dev liblapack-dev libatlas-base-dev gfortran libatlas-dev python-dev),我也回到了旧的numpy版本1.10.1。但没有什么真正有用。 如果一些numpy / snapcrafft专家可以帮助我确定问题,那将会很棒。 非常感谢
答案 0 :(得分:0)
我找到了问题的答案。似乎我使用了错误的numpy版本。使用numpy 1.11.0和以下阶段包它正在运行:
- gcc
- gfortran
- python-dev
- libc6
- libblas3
- liblapack3
- libopenblas-dev
- liblapack-dev
- cython
答案 1 :(得分:0)
除了安装Miniconda(它安装了numpy的旧版本)外,我还使用了以下步骤:
easy_install pip==1.5.6
pip install numpy==1.14.5
请确保您拥有setuptools
和wheel
的最新版本。 Sudo和chroot也可能会影响该过程。
我在以下位置记录了我对Ubuntu Core的个人经历: