Update CPLEX lookup
authorAlpar Juttner <alpar@cs.elte.hu>
Sat, 24 Dec 2011 01:15:59 +0100
changeset 11191818cc848005
parent 1113 53c0dd387001
child 1120 ee581a0ecfbf
Update CPLEX lookup

- References to explicit CPLEX version 9.1 have been removed
- Library file name must either be 'cplex.a' or 'cplex.dll'
cmake/FindCPLEX.cmake
test/CMakeLists.txt
     1.1 --- a/cmake/FindCPLEX.cmake	Tue Dec 20 19:33:51 2011 +0100
     1.2 +++ b/cmake/FindCPLEX.cmake	Sat Dec 24 01:15:59 2011 +0100
     1.3 @@ -2,23 +2,25 @@
     1.4  
     1.5  FIND_PATH(CPLEX_INCLUDE_DIR
     1.6    ilcplex/cplex.h
     1.7 -  PATHS "C:/ILOG/CPLEX91/include"
     1.8 -  PATHS "/opt/ilog/cplex91/include"
     1.9 +  PATHS "C:/ILOG/CPLEX/include"
    1.10 +  PATHS "/opt/ilog/cplex/include"
    1.11    HINTS ${CPLEX_ROOT_DIR}/include
    1.12  )
    1.13  FIND_LIBRARY(CPLEX_LIBRARY
    1.14 -  cplex91
    1.15 -  PATHS "C:/ILOG/CPLEX91/lib/msvc7/stat_mda"
    1.16 -  PATHS "/opt/ilog/cplex91/bin"
    1.17 +  cplex
    1.18 +  PATHS "C:/ILOG/CPLEX/lib/msvc7/stat_mda"
    1.19 +  PATHS "/opt/ilog/cplex/bin"
    1.20    HINTS ${CPLEX_ROOT_DIR}/bin
    1.21 +  HINTS ${CPLEX_ROOT_DIR}/lib
    1.22  )
    1.23  
    1.24  INCLUDE(FindPackageHandleStandardArgs)
    1.25  FIND_PACKAGE_HANDLE_STANDARD_ARGS(CPLEX DEFAULT_MSG CPLEX_LIBRARY CPLEX_INCLUDE_DIR)
    1.26  
    1.27  FIND_PATH(CPLEX_BIN_DIR
    1.28 -  cplex91.dll
    1.29 -  PATHS "C:/ILOG/CPLEX91/bin/x86_win32"
    1.30 +  cplex.dll
    1.31 +  PATHS "C:/ILOG/CPLEX/bin/x86_win32"
    1.32 +  HINTS ${CPLEX_ROOT_DIR}/bin
    1.33  )
    1.34  
    1.35  IF(CPLEX_FOUND)
     2.1 --- a/test/CMakeLists.txt	Tue Dec 20 19:33:51 2011 +0100
     2.2 +++ b/test/CMakeLists.txt	Sat Dec 24 01:15:59 2011 +0100
     2.3 @@ -82,7 +82,7 @@
     2.4      GET_TARGET_PROPERTY(TARGET_LOC lp_test LOCATION)
     2.5      GET_FILENAME_COMPONENT(TARGET_PATH ${TARGET_LOC} PATH)
     2.6      ADD_CUSTOM_COMMAND(TARGET lp_test POST_BUILD
     2.7 -      COMMAND ${CMAKE_COMMAND} -E copy ${CPLEX_BIN_DIR}/cplex91.dll ${TARGET_PATH}
     2.8 +      COMMAND ${CMAKE_COMMAND} -E copy ${CPLEX_BIN_DIR}/cplex.dll ${TARGET_PATH}
     2.9      )
    2.10    ENDIF()
    2.11  ENDIF()
    2.12 @@ -124,7 +124,7 @@
    2.13      GET_TARGET_PROPERTY(TARGET_LOC mip_test LOCATION)
    2.14      GET_FILENAME_COMPONENT(TARGET_PATH ${TARGET_LOC} PATH)
    2.15      ADD_CUSTOM_COMMAND(TARGET mip_test POST_BUILD
    2.16 -      COMMAND ${CMAKE_COMMAND} -E copy ${CPLEX_BIN_DIR}/cplex91.dll ${TARGET_PATH}
    2.17 +      COMMAND ${CMAKE_COMMAND} -E copy ${CPLEX_BIN_DIR}/cplex.dll ${TARGET_PATH}
    2.18      )
    2.19    ENDIF()
    2.20  ENDIF()