mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-21 10:43:46 +00:00
cmake - also use find_package to find Eigen3
This commit is contained in:
+10
-2
@@ -795,8 +795,16 @@ endif(MSVC)
|
|||||||
|
|
||||||
|
|
||||||
# Ensure other dependencies are provided.
|
# Ensure other dependencies are provided.
|
||||||
if(NOT EIGEN_DIR OR NOT EXISTS "${EIGEN_DIR}")
|
if(NOT EXISTS "${EIGEN_DIR}")
|
||||||
message(FATAL_ERROR "EIGEN_DIR is not provided or provided folder doesn't exist (current value: '${EIGEN_DIR}').")
|
find_package(Eigen3 CONFIG)
|
||||||
|
if(NOT Eigen3_DIR)
|
||||||
|
message(
|
||||||
|
FATAL_ERROR
|
||||||
|
"EIGEN_DIR is not provided or provided folder doesn't exist (current value: '${EIGEN_DIR}'). "
|
||||||
|
"Also couldn't find Eigen3 as a package."
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
link_libraries(Eigen3::Eigen)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user