author | Akos Ladanyi <ladanyi@tmit.bme.hu> |
Tue, 26 May 2009 17:49:10 +0100 | |
changeset 720 | e4378da8cfcb |
parent 715 | 7e13120d90a2 |
child 722 | c5dc4d3124aa |
permissions | -rw-r--r-- |
alpar@225 | 1 |
CMAKE_MINIMUM_REQUIRED(VERSION 2.6) |
alpar@225 | 2 |
|
alpar@503 | 3 |
IF(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@503 | 4 |
INCLUDE(${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@503 | 5 |
ELSE(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@503 | 6 |
SET(PROJECT_NAME "LEMON") |
alpar@503 | 7 |
SET(PROJECT_VERSION "hg-tip" CACHE STRING "LEMON version string.") |
alpar@503 | 8 |
ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@225 | 9 |
|
alpar@225 | 10 |
PROJECT(${PROJECT_NAME}) |
alpar@225 | 11 |
|
ladanyi@596 | 12 |
SET(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) |
alpar@225 | 13 |
|
alpar@225 | 14 |
INCLUDE(FindDoxygen) |
alpar@225 | 15 |
INCLUDE(FindGhostscript) |
ladanyi@496 | 16 |
FIND_PACKAGE(GLPK 4.33) |
ladanyi@667 | 17 |
FIND_PACKAGE(CPLEX) |
ladanyi@668 | 18 |
FIND_PACKAGE(COIN) |
ladanyi@496 | 19 |
|
alpar@515 | 20 |
INCLUDE(CheckTypeSize) |
ladanyi@540 | 21 |
CHECK_TYPE_SIZE("long long" LEMON_LONG_LONG) |
alpar@515 | 22 |
|
alpar@225 | 23 |
ENABLE_TESTING() |
alpar@225 | 24 |
|
alpar@225 | 25 |
ADD_SUBDIRECTORY(lemon) |
ladanyi@596 | 26 |
IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR}) |
ladanyi@596 | 27 |
ADD_SUBDIRECTORY(demo) |
ladanyi@596 | 28 |
ADD_SUBDIRECTORY(tools) |
ladanyi@596 | 29 |
ADD_SUBDIRECTORY(doc) |
ladanyi@596 | 30 |
ADD_SUBDIRECTORY(test) |
ladanyi@596 | 31 |
ENDIF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR}) |
alpar@225 | 32 |
|
ladanyi@599 | 33 |
IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR}) |
ladanyi@599 | 34 |
IF(WIN32) |
ladanyi@599 | 35 |
SET(CPACK_PACKAGE_NAME ${PROJECT_NAME}) |
ladanyi@599 | 36 |
SET(CPACK_PACKAGE_VENDOR "EGRES") |
ladanyi@599 | 37 |
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY |
kpeter@705 | 38 |
"LEMON - Library for Efficient Modeling and Optimization in Networks") |
ladanyi@599 | 39 |
SET(CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/LICENSE") |
alpar@225 | 40 |
|
ladanyi@599 | 41 |
SET(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) |
alpar@225 | 42 |
|
ladanyi@599 | 43 |
SET(CPACK_PACKAGE_INSTALL_DIRECTORY |
ladanyi@599 | 44 |
"${PROJECT_NAME} ${PROJECT_VERSION}") |
ladanyi@599 | 45 |
SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY |
ladanyi@599 | 46 |
"${PROJECT_NAME} ${PROJECT_VERSION}") |
alpar@225 | 47 |
|
ladanyi@599 | 48 |
SET(CPACK_COMPONENTS_ALL headers library html_documentation bin) |
alpar@225 | 49 |
|
ladanyi@599 | 50 |
SET(CPACK_COMPONENT_HEADERS_DISPLAY_NAME "C++ headers") |
ladanyi@599 | 51 |
SET(CPACK_COMPONENT_LIBRARY_DISPLAY_NAME "Dynamic-link library") |
ladanyi@599 | 52 |
SET(CPACK_COMPONENT_BIN_DISPLAY_NAME "Command line utilities") |
ladanyi@599 | 53 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DISPLAY_NAME "HTML documentation") |
alpar@225 | 54 |
|
ladanyi@599 | 55 |
SET(CPACK_COMPONENT_HEADERS_DESCRIPTION |
ladanyi@599 | 56 |
"C++ header files") |
ladanyi@599 | 57 |
SET(CPACK_COMPONENT_LIBRARY_DESCRIPTION |
ladanyi@599 | 58 |
"DLL and import library") |
ladanyi@599 | 59 |
SET(CPACK_COMPONENT_BIN_DESCRIPTION |
ladanyi@599 | 60 |
"Command line utilities") |
ladanyi@599 | 61 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DESCRIPTION |
ladanyi@599 | 62 |
"Doxygen generated documentation") |
alpar@225 | 63 |
|
ladanyi@599 | 64 |
SET(CPACK_COMPONENT_HEADERS_DEPENDS library) |
alpar@225 | 65 |
|
ladanyi@599 | 66 |
SET(CPACK_COMPONENT_HEADERS_GROUP "Development") |
ladanyi@599 | 67 |
SET(CPACK_COMPONENT_LIBRARY_GROUP "Development") |
ladanyi@599 | 68 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_GROUP "Documentation") |
alpar@225 | 69 |
|
ladanyi@599 | 70 |
SET(CPACK_COMPONENT_GROUP_DEVELOPMENT_DESCRIPTION |
ladanyi@599 | 71 |
"Components needed to develop software using LEMON") |
ladanyi@599 | 72 |
SET(CPACK_COMPONENT_GROUP_DOCUMENTATION_DESCRIPTION |
ladanyi@599 | 73 |
"Documentation of LEMON") |
alpar@225 | 74 |
|
ladanyi@599 | 75 |
SET(CPACK_ALL_INSTALL_TYPES Full Developer) |
alpar@225 | 76 |
|
ladanyi@599 | 77 |
SET(CPACK_COMPONENT_HEADERS_INSTALL_TYPES Developer Full) |
ladanyi@599 | 78 |
SET(CPACK_COMPONENT_LIBRARY_INSTALL_TYPES Developer Full) |
ladanyi@599 | 79 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_INSTALL_TYPES Full) |
alpar@225 | 80 |
|
ladanyi@599 | 81 |
SET(CPACK_GENERATOR "NSIS") |
ladanyi@599 | 82 |
SET(CPACK_NSIS_MUI_ICON "${PROJECT_SOURCE_DIR}/cmake/nsis/lemon.ico") |
ladanyi@599 | 83 |
SET(CPACK_NSIS_MUI_UNIICON "${PROJECT_SOURCE_DIR}/cmake/nsis/uninstall.ico") |
ladanyi@599 | 84 |
#SET(CPACK_PACKAGE_ICON "${PROJECT_SOURCE_DIR}/cmake/nsis\\\\installer.bmp") |
ladanyi@599 | 85 |
SET(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\\\lemon.ico") |
ladanyi@599 | 86 |
SET(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY} ${PROJECT_NAME}") |
ladanyi@599 | 87 |
SET(CPACK_NSIS_HELP_LINK "http:\\\\\\\\lemon.cs.elte.hu") |
ladanyi@599 | 88 |
SET(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\\\\\lemon.cs.elte.hu") |
ladanyi@599 | 89 |
SET(CPACK_NSIS_CONTACT "lemon-user@lemon.cs.elte.hu") |
ladanyi@599 | 90 |
SET(CPACK_NSIS_CREATE_ICONS_EXTRA " |
ladanyi@599 | 91 |
CreateShortCut \\\"$SMPROGRAMS\\\\$STARTMENU_FOLDER\\\\Documentation.lnk\\\" \\\"$INSTDIR\\\\share\\\\doc\\\\index.html\\\" |
ladanyi@599 | 92 |
") |
ladanyi@599 | 93 |
SET(CPACK_NSIS_DELETE_ICONS_EXTRA " |
ladanyi@599 | 94 |
!insertmacro MUI_STARTMENU_GETFOLDER Application $MUI_TEMP |
ladanyi@599 | 95 |
Delete \\\"$SMPROGRAMS\\\\$MUI_TEMP\\\\Documentation.lnk\\\" |
ladanyi@599 | 96 |
") |
alpar@225 | 97 |
|
ladanyi@599 | 98 |
INCLUDE(CPack) |
ladanyi@599 | 99 |
ENDIF(WIN32) |
ladanyi@599 | 100 |
ENDIF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR}) |