diff --git a/lemon/CMakeLists.txt b/lemon/CMakeLists.txt --- a/lemon/CMakeLists.txt +++ b/lemon/CMakeLists.txt @@ -1,7 +1,6 @@ INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR} - ${GLPK_INCLUDE_DIR} ) CONFIGURE_FILE( @@ -19,6 +18,12 @@ IF(HAVE_GLPK) SET(LEMON_SOURCES ${LEMON_SOURCES} glpk.cc) + INCLUDE_DIRECTORIES(${GLPK_INCLUDE_DIR}) + IF(WIN32) + INSTALL(FILES ${GLPK_BIN_DIR}/glpk.dll DESTINATION bin) + INSTALL(FILES ${GLPK_BIN_DIR}/libltdl3.dll DESTINATION bin) + INSTALL(FILES ${GLPK_BIN_DIR}/zlib1.dll DESTINATION bin) + ENDIF(WIN32) ENDIF(HAVE_GLPK) ADD_LIBRARY(lemon ${LEMON_SOURCES}) @@ -33,9 +38,3 @@ DESTINATION include/lemon COMPONENT headers FILES_MATCHING PATTERN "*.h") - -IF(WIN32) - INSTALL(FILES ${GLPK_BIN_DIR}/glpk.dll DESTINATION bin) - INSTALL(FILES ${GLPK_BIN_DIR}/libltdl3.dll DESTINATION bin) - INSTALL(FILES ${GLPK_BIN_DIR}/zlib1.dll DESTINATION bin) -ENDIF(WIN32)