Commit 31882f34 authored by David Bommes's avatar David Bommes

changed eigen3 finder to conform with standard

git-svn-id: http://www.openflipper.org/svnrepo/CoMISo/trunk@219 1355f012-dd97-4b2f-ae87-10fa9f823a57
parent ba3f10bb
# - Try to find EIGEN3
# Once done this will define
# EIGEN3_FOUND - System has EIGEN3
# EIGEN3_INCLUDE_DIRS - The EIGEN3 include directories
if (EIGEN3_INCLUDE_DIR)
# in cache already
set(EIGEN3_FOUND TRUE)
set(EIGEN3_INCLUDE_DIRS "${EIGEN3_INCLUDE_DIR}" )
else (EIGEN3_INCLUDE_DIR)
find_path( EIGEN3_INCLUDE_DIR
NAMES Eigen/Dense
PATHS $ENV{EIGEN_DIR}
/usr/include/eigen3
/usr/local/include
/usr/local/include/eigen3/
/opt/local/include/eigen3/
"c:\\libs\\eigen3\\include"
"c:\\libs\\eigen\\include"
${PROJECT_SOURCE_DIR}/MacOS/Libs/eigen3/include
../../External/include
${module_file_path}/../../../External/include
)
set(EIGEN3_INCLUDE_DIRS "${EIGEN3_INCLUDE_DIR}" )
include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set LIBCPLEX_FOUND to TRUE
# if all listed variables are TRUE
find_package_handle_standard_args(EIGEN3 DEFAULT_MSG
EIGEN3_INCLUDE_DIR)
mark_as_advanced(EIGEN3_INCLUDE_DIR)
endif(EIGEN3_INCLUDE_DIR)
# - Find Eigen3
# Find the native GMM headers and libraries.
#
# Eigen3_INCLUDE_DIR - where to find <Eigen/Dense>, etc.
# Eigen3_FOUND - True if Eigen3 found.
IF (Eigen3_INCLUDE_DIR)
# Already in cache, be silent
SET(Eigen3_FIND_QUIETLY TRUE)
ENDIF (Eigen3_INCLUDE_DIR)
GET_FILENAME_COMPONENT(module_file_path ${CMAKE_CURRENT_LIST_FILE} PATH )
# Look for the header file.
FIND_PATH(Eigen3_INCLUDE_DIR NAMES Eigen/Dense
PATHS /usr/include/eigen3
/usr/local/include
/usr/local/include/eigen3/
/opt/local/include/eigen3/
"c:\\libs\\eigen3\\include"
"c:\\libs\\eigen\\include"
${PROJECT_SOURCE_DIR}/MacOS/Libs/eigen3/include
../../External/include
${module_file_path}/../../../External/include)
# Copy the results to the output variables.
IF(Eigen3_INCLUDE_DIR )
SET(Eigen3_FOUND 1)
SET(Eigen3_INCLUDE_DIR ${Eigen3_INCLUDE_DIR})
ELSE(Eigen3_INCLUDE_DIR )
SET(Eigen3_FOUND 0)
SET(Eigen3_INCLUDE_DIR)
ENDIF(Eigen3_INCLUDE_DIR )
# Report the results.
IF(NOT Eigen3_FOUND)
SET(Eigen3_DIR_MESSAGE
"Eigen3 was not found. Make sure Eigen3_INCLUDE_DIR is set to the directories containing the include and lib files for Eigen3. .")
ELSE (NOT Eigen3_FOUND)
IF(NOT Eigen3_FIND_QUIETLY)
MESSAGE(STATUS "Looking for Eigen3 - found")
ENDIF(NOT Eigen3_FIND_QUIETLY)
ENDIF(NOT Eigen3_FOUND)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment