hitxiaomi/pnp_solver (github.com)
mkdir build
cd build
cmake ..
make
-- The C compiler identification is GNU 11.3.0
-- The CXX compiler identification is GNU 11.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning at cmake/FindEigen3.cmake:28 (message):
Failed to find Eigen3. Please, define the path manually.
Call Stack (most recent call first):
CMakeLists.txt:13 (find_package)
-- EIGEN3_DIR:EIGEN3_INCLUDE_DIR-NOTFOUND
-- Configuring done
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
EIGEN3_INCLUDE_DIR
used as include directory in directory /home/tieren/github/pnp_solver
used as include directory in directory /home/tieren/github/pnp_solver
used as include directory in directory /home/tieren/github/pnp_solver
used as include directory in directory /home/tieren/github/pnp_solver
CMake Error in CMakeLists.txt:
Found relative path while evaluating include directories of "test_dlt":
"EIGEN3_INCLUDE_DIR-NOTFOUND"
CMake Error in CMakeLists.txt:
Found relative path while evaluating include directories of "test_epnp":
"EIGEN3_INCLUDE_DIR-NOTFOUND"
-- Generating done
CMake Generate step failed. Build files cannot be regenerated correctly.
eigen3 这个库没有被安装
解决 CMake Error at CMakeLists.txt:11 (message): EIGEN3 not found._eigen3_dir-notfound-CSDN博客
sudo apt install libeigen3-dev
安装好这个之后就能make成功了