cmake/FindCPLEX.cmake
author Alpar Juttner <alpar@cs.elte.hu>
Sun, 26 Apr 2009 16:36:23 +0100
changeset 673 58357e986a08
child 674 20dac2104519
permissions -rw-r--r--
Merge
ladanyi@667
     1
FIND_PATH(CPLEX_INCLUDE_DIR
ladanyi@667
     2
  ilcplex/cplex.h
ladanyi@667
     3
  PATHS "C:/ILOG/CPLEX91/include")
ladanyi@667
     4
ladanyi@667
     5
FIND_LIBRARY(CPLEX_LIBRARY
ladanyi@667
     6
  NAMES cplex91
ladanyi@667
     7
  PATHS "C:/ILOG/CPLEX91/lib/msvc7/stat_mda")
ladanyi@667
     8
ladanyi@667
     9
INCLUDE(FindPackageHandleStandardArgs)
ladanyi@667
    10
FIND_PACKAGE_HANDLE_STANDARD_ARGS(CPLEX DEFAULT_MSG CPLEX_LIBRARY CPLEX_INCLUDE_DIR)
ladanyi@667
    11
ladanyi@667
    12
FIND_PATH(CPLEX_BIN_DIR
ladanyi@667
    13
  cplex91.dll
ladanyi@667
    14
  PATHS "C:/ILOG/CPLEX91/bin/x86_win32")
ladanyi@667
    15
ladanyi@667
    16
IF(CPLEX_FOUND)
ladanyi@667
    17
  SET(CPLEX_INCLUDE_DIRS ${CPLEX_INCLUDE_DIR})
ladanyi@667
    18
  SET(CPLEX_LIBRARIES ${CPLEX_LIBRARY})
ladanyi@667
    19
ENDIF(CPLEX_FOUND)
ladanyi@667
    20
ladanyi@667
    21
MARK_AS_ADVANCED(CPLEX_LIBRARY CPLEX_INCLUDE_DIR CPLEX_BIN_DIR)
ladanyi@667
    22
ladanyi@667
    23
IF(CPLEX_FOUND)
ladanyi@667
    24
  SET(HAVE_LP TRUE)
ladanyi@667
    25
  SET(HAVE_MIP TRUE)
ladanyi@667
    26
  SET(HAVE_CPLEX TRUE)
ladanyi@667
    27
ENDIF(CPLEX_FOUND)