【发布时间】:2017-09-07 11:17:13
【问题描述】:
我正在 linux(ubuntu) 中安装 Pdal 库,使用:pip install pdal 命令并收到以下错误:
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++
In file included from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarraytypes.h:1777:0,
from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarrayobject.h:18,
from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/arrayobject.h:4,
from pdal/libpdalpython.cpp:487:
/usr/lib/python2.7/dist-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: #warning "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
#warning "Using deprecated NumPy API, disable it by " \
^
pdal/libpdalpython.cpp:489:32: **fatal error:** pdal/plang/Array.hpp: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
我搜索了此错误的解决方案,但没有得到任何相关信息。
【问题讨论】:
-
请先说明您是如何安装 PDAL 的,因为
pip install pdal命令只安装绑定。另外,您正在安装(或尝试安装)哪个版本的 PDAL? -
好的。我通过 osGeo4w 安装了 PDAL 1.5.0,然后我克隆了 PDAL 并为我的 python 代码尝试 pip install pdal。我是所有这些事情的初学者。请您提供在 ubuntu 中安装 PDAL 的步骤。我阅读了 PDAL 文档进行安装,但没有得到太多正确安装。
-
我建议查看here 以获取 Unix 编译说明。这里仍然存在一些混淆,因为您已经指出使用仅适用于 Windows 的 OSGeo4W 并且需要在 Ubuntu 上使用它。它是哪一个?使用 Docker 映像运行是否适合您?它基于 Ubuntu。
-
其实我是用wine在ubuntu中安装osGeo4w的。
-
在重新运行
pip:apt-cache search pdal之前尝试安装此命令的结果包。
标签: python linux pip point-clouds