how to solve cmake error
kisu2511 opened this issue · 2 comments
recently,
i searched your code, and your code is very well made for PBD.
so i want to look around your code.
however, this project makes error when using cmake.
the error is about EIGEN3_INCLUDE_DIR error.
how can i solve this problem? can you tell me some tips or solution?
below is error massage from cmake
CMake Error at C:/Program Files/CMake/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
Could NOT find Eigen3 (missing: EIGEN3_INCLUDE_DIR EIGEN3_VERSION_OK)
(Required is at least version "2.91.0")
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
cmake/Modules/FindEigen3.cmake:76 (find_package_handle_standard_args)
discregrid/CMakeLists.txt:86 (find_package)
Thank you in advance.
Hi kisu2511,
Eigen is a linear algebra (header-only) library and is the only non-included dependency of this project. On Linux the library can be installed by simply installing the eigen package, e.g. on Ubuntu libeigen3-dev
. For Windows, you have to download Eigen from here and set the CMake variable EIGEN3_INCLUDE_DIR
to the Eigen install directory. Then, the code should compile.
Best, Dan
Hi Dan,
following your suggestion, I downloaded and set the dir and it worked well.
also, it built well in VS2017 through cmake.
Thank you for your fast reply.
Best, kisu2511