Я установил ceres-solver
, используя
brew install ceres-solver
в macOS.
Я создал CMake.txt
для клиентского проекта, который использует Ceres.
cmake_minimum_required(VERSION 2.8)
project(helloworld)
find_package(Ceres REQUIRED)
include_directories(${CERES_INCLUDE_DIRS})
# helloworld
add_executable(helloworld helloworld.cpp)
target_link_libraries(helloworld ${CERES_LIBRARIES})
Однако, когда я запускаю следующую команду
cmake . -Bbuild
я получаю следующую ошибку
CMake Error at /usr/local/lib/cmake/Ceres/CeresConfig.cmake:88 (message):
Failed to find Ceres - Found Eigen dependency, but the version of Eigen
found (3.3.90) does not exactly match the version of Eigen Ceres was
compiled with (3.3.7). This can cause subtle bugs by triggering violations
of the One Definition Rule. See the Wikipedia article
http://en.wikipedia.org/wiki/One_Definition_Rule for more details
Call Stack (most recent call first):
/usr/local/lib/cmake/Ceres/CeresConfig.cmake:223 (ceres_report_not_found)
CMakeLists.txt:5 (find_package)
CMake Error at CMakeLists.txt:5 (find_package):
Found package configuration file:
/usr/local/lib/cmake/Ceres/CeresConfig.cmake
but it set Ceres_FOUND to FALSE so package "Ceres" is considered to be NOT
FOUND.
-- Configuring incomplete, errors occurred!
Как удалить конфликтующую версиюЭйген? Я не помню, как я установил это в прошлом. Я также попытался запустить brew uninstall Eigen
, но это не помогло устранить ошибку.
Спасибо за любую помощь.