Issue when installing pangolin by `install_all.sh`
Closed this issue · 1 comments
Hello,
I followed the README file but stuck at installing packages by install.sh
I checked the log it failed at when installing pangolin.
When it is trying to build pangolin, it said
[ 1%] Building CXX object src/CMakeFiles/_pangolin.dir/video/video.cpp.o
[ 2%] Building C object src/CMakeFiles/_pangolin.dir/fonts.c.o
[ 3%] Linking CXX static library lib_pangolin.a
[ 72%] Built target _pangolin
[ 73%] Linking CXX executable SimplePlot
[ 74%] Linking CXX executable SimpleVideo
[ 75%] Building CXX object python/CMakeFiles/pangolin.dir/pangolin.cpp.o
[ 78%] Linking CXX executable SimpleMultiDisplay
[ 78%] Linking CXX executable HelloPangolin
[ 78%] Linking CXX executable SimpleScene
[ 79%] Linking CXX executable SimpleDisplayImage
[ 80%] Linking CXX executable SimpleDisplay
In file included from /home/hao/PycharmProjects/pyslam/thirdparty/pangolin/external/pybind11/include/pybind11/pytypes.h:12:0,
from /home/hao/PycharmProjects/pyslam/thirdparty/pangolin/external/pybind11/include/pybind11/cast.h:13,
from /home/hao/PycharmProjects/pyslam/thirdparty/pangolin/external/pybind11/include/pybind11/attr.h:13,
from /home/hao/PycharmProjects/pyslam/thirdparty/pangolin/external/pybind11/include/pybind11/pybind11.h:43,
from /home/hao/PycharmProjects/pyslam/thirdparty/pangolin/python/pangolin.cpp:1:
**/home/hao/PycharmProjects/pyslam/thirdparty/pangolin/external/pybind11/include/pybind11/detail/common.h:111:10: fatal error: Python.h: No such file or directory**
#include <Python.h>
^~~~~~~~~~
compilation terminated.
python/CMakeFiles/pangolin.dir/build.make:62: recipe for target 'python/CMakeFiles/pangolin.dir/pangolin.cpp.o' failed
make[2]: *** [python/CMakeFiles/pangolin.dir/pangolin.cpp.o] Error 1
CMakeFiles/Makefile2:190: recipe for target 'python/CMakeFiles/pangolin.dir/all' failed
make[1]: *** [python/CMakeFiles/pangolin.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 81%] Built target SimpleMultiDisplay
[ 82%] Built target SimplePlot
[ 83%] Built target SimpleDisplayImage
[ 83%] Built target HelloPangolin
[ 84%] Built target SimpleVideo
[ 85%] Built target SimpleScene
[ 86%] Built target SimpleDisplay
Makefile:151: recipe for target 'all' failed
make: *** [all] Error 2
I have searched this issue here and one suggestion said the python3-dev package is missing.
The python3-dev
packagte is installed actually because when I tried to install it said 0 to upgrade, 0 to newly install, 0 to remove and 0 not to upgrade.
I have multiple python version under /usr/bin/
directory. The system is Ubuntu 18.04.6 LTS.
Please help
Hi,
thanks for your feedback. I actually tried to reproduce the problem but I can't succeed. My rough guess is the problems you are experiencing may be due to the multiple python configuration you are using. Indeed, I don't have enough information to be able to help you.
I strongly recommend following the suggestion I shared here
#63 (comment)
and use the procedure reported in the following link: it creates a new virtual python environment and should work well
https://github.com/luigifreda/pyslam#install-pyslam-in-a-custom-python-virtual-environment