Commit 46d1c648 authored by David Bommes's avatar David Bommes

Finder updates for correct metis and HSL inclusion

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@17857 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 8e4b2592
...@@ -53,13 +53,20 @@ ELSE( WIN32 ) ...@@ -53,13 +53,20 @@ ELSE( WIN32 )
add_definitions( -DHAVE_CSTDDEF ) add_definitions( -DHAVE_CSTDDEF )
# set optional path to HSL Solver # set optional path to HSL Solver for dynamic usage
find_path(IPOPT_HSL_LIBRARY_DIR find_path(IPOPT_HSL_LIBRARY_DIR
NAMES libhsl.so NAMES libhsl.so
libhsl.dylib libhsl.dylib
PATHS "$ENV{IPOPT_HSL_LIBRARY_PATH}" PATHS "$ENV{IPOPT_HSL_LIBRARY_PATH}"
"$ENV{HOME}/opt/HSL/lib" "$ENV{HOME}/opt/HSL/lib"
) )
# find HSL library for fixed linking of solvers
find_library( IPOPT_HSL_LIBRARY
coinhsl
PATHS "$ENV{IPOPT_HOME}/lib"
"/usr/lib" )
IF( IPOPT_HSL_LIBRARY_DIR) IF( IPOPT_HSL_LIBRARY_DIR)
IF( NOT IPOPT_FIND_QUIETLY ) IF( NOT IPOPT_FIND_QUIETLY )
...@@ -72,9 +79,13 @@ ELSE( WIN32 ) ...@@ -72,9 +79,13 @@ ELSE( WIN32 )
set(IPOPT_INCLUDE_DIRS "${IPOPT_INCLUDE_DIR}" ) set(IPOPT_INCLUDE_DIRS "${IPOPT_INCLUDE_DIR}" )
set(IPOPT_LIBRARIES "${IPOPT_LIBRARY}" ) set(IPOPT_LIBRARIES "${IPOPT_LIBRARY}" )
IF(IPOPT_HSL_LIBRARY)
LIST( APPEND IPOPT_LIBRARIES "${IPOPT_HSL_LIBRARY}")
ENDIF(IPOPT_HSL_LIBRARY)
include(FindPackageHandleStandardArgs) include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set LIBCPLEX_FOUND to TRUE # handle the QUIETLY and REQUIRED arguments and set LIBIPOPT_FOUND to TRUE
# if all listed variables are TRUE # if all listed variables are TRUE
find_package_handle_standard_args(IPOPT DEFAULT_MSG find_package_handle_standard_args(IPOPT DEFAULT_MSG
IPOPT_LIBRARY IPOPT_INCLUDE_DIR) IPOPT_LIBRARY IPOPT_INCLUDE_DIR)
......
...@@ -97,7 +97,7 @@ else( WIN32 ) ...@@ -97,7 +97,7 @@ else( WIN32 )
NAMES metis NAMES metis
PATHS ${SUITESPARSE_LIBRARY_DIR} ) PATHS ${SUITESPARSE_LIBRARY_DIR} )
IF (SUITESPARSE_METIS_LIBRARY) IF (SUITESPARSE_METIS_LIBRARY)
list ( APPEND SUITESPARSE_LIBRARIES metis) list ( APPEND SUITESPARSE_LIBRARIES ${SUITESPARSE_METIS_LIBRARY})
ENDIF(SUITESPARSE_METIS_LIBRARY) ENDIF(SUITESPARSE_METIS_LIBRARY)
if(EXISTS "${CHOLMOD_INCLUDE_DIR}/SuiteSparseQR.hpp") if(EXISTS "${CHOLMOD_INCLUDE_DIR}/SuiteSparseQR.hpp")
...@@ -119,7 +119,6 @@ else( WIN32 ) ...@@ -119,7 +119,6 @@ else( WIN32 )
endif( WIN32 ) endif( WIN32 )
IF (SUITESPARSE_INCLUDE_DIRS AND SUITESPARSE_LIBRARIES) IF (SUITESPARSE_INCLUDE_DIRS AND SUITESPARSE_LIBRARIES)
IF(WIN32) IF(WIN32)
list (APPEND SUITESPARSE_INCLUDE_DIRS ${CHOLMOD_INCLUDE_DIR}/../../UFconfig ) list (APPEND SUITESPARSE_INCLUDE_DIRS ${CHOLMOD_INCLUDE_DIR}/../../UFconfig )
......
...@@ -83,7 +83,14 @@ ELSE (NOT TAUCS_FOUND) ...@@ -83,7 +83,14 @@ ELSE (NOT TAUCS_FOUND)
MESSAGE(STATUS "Looking for TAUCS - found") MESSAGE(STATUS "Looking for TAUCS - found")
ENDIF(NOT TAUCS_FIND_QUIETLY) ENDIF(NOT TAUCS_FIND_QUIETLY)
IF ( NOT WIN32 ) IF ( NOT WIN32 )
SET(TAUCS_LIBRARY "${TAUCS_LIBRARY};metis") # Metis
FIND_LIBRARY( TAUCS_METIS_LIBRARY
NAMES metis
PATHS "${CGAL_TAUCS_DIR}/lib" )
IF (TAUCS_METIS_LIBRARY)
list ( APPEND TAUCS_LIBRARY ${TAUCS_METIS_LIBRARY})
ENDIF(TAUCS_METIS_LIBRARY)
SET(TAUCS_LIBRARY "${TAUCS_LIBRARY}")
ELSE ( NOT WIN32 ) ELSE ( NOT WIN32 )
SET(TAUCS_LIBRARY "${TAUCS_LIBRARY}") SET(TAUCS_LIBRARY "${TAUCS_LIBRARY}")
ENDIF( NOT WIN32 ) ENDIF( NOT WIN32 )
......
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