author | Alpar Juttner <alpar@cs.elte.hu> |
Tue, 31 Mar 2009 16:21:30 +0100 | |
branch | 1.0 |
changeset 392 | ca12939f8b00 |
parent 376 | d3524090d5e2 |
parent 377 | 97070bd10b98 |
child 396 | 4b558ee0d4f5 |
permissions | -rw-r--r-- |
alpar@225 | 1 |
CMAKE_MINIMUM_REQUIRED(VERSION 2.6) |
alpar@225 | 2 |
|
alpar@360 | 3 |
IF(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@360 | 4 |
INCLUDE(${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@360 | 5 |
ELSE(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@360 | 6 |
SET(PROJECT_NAME "LEMON") |
alpar@360 | 7 |
SET(PROJECT_VERSION "hg-tip" CACHE STRING "LEMON version string.") |
alpar@360 | 8 |
ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
alpar@225 | 9 |
|
alpar@225 | 10 |
PROJECT(${PROJECT_NAME}) |
alpar@225 | 11 |
|
alpar@225 | 12 |
SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake) |
alpar@225 | 13 |
|
alpar@357 | 14 |
IF(MSVC) |
alpar@357 | 15 |
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4250 /wd4355 /wd4800 /wd4996") |
alpar@357 | 16 |
# Suppressed warnings: |
alpar@357 | 17 |
# C4250: 'class1' : inherits 'class2::member' via dominance |
alpar@357 | 18 |
# C4355: 'this' : used in base member initializer list |
alpar@357 | 19 |
# C4800: 'type' : forcing value to bool 'true' or 'false' (performance warning) |
alpar@357 | 20 |
# C4996: 'function': was declared deprecated |
alpar@357 | 21 |
ENDIF(MSVC) |
alpar@357 | 22 |
|
alpar@225 | 23 |
INCLUDE(FindDoxygen) |
alpar@225 | 24 |
INCLUDE(FindGhostscript) |
alpar@225 | 25 |
|
alpar@372 | 26 |
INCLUDE(CheckTypeSize) |
alpar@372 | 27 |
CHECK_TYPE_SIZE("long long" LONG_LONG) |
alpar@372 | 28 |
|
alpar@225 | 29 |
ENABLE_TESTING() |
alpar@225 | 30 |
|
alpar@225 | 31 |
ADD_SUBDIRECTORY(lemon) |
alpar@225 | 32 |
ADD_SUBDIRECTORY(demo) |
alpar@225 | 33 |
ADD_SUBDIRECTORY(doc) |
alpar@225 | 34 |
ADD_SUBDIRECTORY(test) |
alpar@225 | 35 |
|
alpar@225 | 36 |
IF(WIN32) |
alpar@225 | 37 |
SET(CPACK_PACKAGE_NAME ${PROJECT_NAME}) |
ladanyi@359 | 38 |
SET(CPACK_PACKAGE_VENDOR "EGRES") |
alpar@225 | 39 |
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY |
ladanyi@236 | 40 |
"LEMON - Library of Efficient Models and Optimization in Networks") |
alpar@225 | 41 |
SET(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE") |
alpar@225 | 42 |
|
alpar@225 | 43 |
SET(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) |
alpar@225 | 44 |
|
alpar@225 | 45 |
SET(CPACK_PACKAGE_INSTALL_DIRECTORY |
ladanyi@274 | 46 |
"${PROJECT_NAME} ${PROJECT_VERSION}") |
alpar@225 | 47 |
SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY |
ladanyi@274 | 48 |
"${PROJECT_NAME} ${PROJECT_VERSION}") |
alpar@225 | 49 |
|
ladanyi@359 | 50 |
SET(CPACK_COMPONENTS_ALL headers library html_documentation) |
alpar@225 | 51 |
|
ladanyi@359 | 52 |
SET(CPACK_COMPONENT_HEADERS_DISPLAY_NAME "C++ headers") |
ladanyi@359 | 53 |
SET(CPACK_COMPONENT_LIBRARY_DISPLAY_NAME "Dynamic-link library") |
ladanyi@359 | 54 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DISPLAY_NAME "HTML documentation") |
alpar@225 | 55 |
|
ladanyi@359 | 56 |
SET(CPACK_COMPONENT_HEADERS_DESCRIPTION |
ladanyi@359 | 57 |
"C++ header files") |
ladanyi@359 | 58 |
SET(CPACK_COMPONENT_LIBRARY_DESCRIPTION |
ladanyi@359 | 59 |
"DLL and import library") |
ladanyi@359 | 60 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DESCRIPTION |
ladanyi@359 | 61 |
"Doxygen generated documentation") |
alpar@225 | 62 |
|
ladanyi@359 | 63 |
SET(CPACK_COMPONENT_HEADERS_DEPENDS library) |
alpar@225 | 64 |
|
ladanyi@359 | 65 |
SET(CPACK_COMPONENT_HEADERS_GROUP "Development") |
ladanyi@359 | 66 |
SET(CPACK_COMPONENT_LIBRARY_GROUP "Development") |
ladanyi@359 | 67 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_GROUP "Documentation") |
alpar@225 | 68 |
|
ladanyi@359 | 69 |
SET(CPACK_COMPONENT_GROUP_DEVELOPMENT_DESCRIPTION |
ladanyi@359 | 70 |
"Components needed to develop software using LEMON") |
ladanyi@359 | 71 |
SET(CPACK_COMPONENT_GROUP_DOCUMENTATION_DESCRIPTION |
ladanyi@359 | 72 |
"Documentation of LEMON") |
alpar@225 | 73 |
|
ladanyi@359 | 74 |
SET(CPACK_ALL_INSTALL_TYPES Full Developer) |
alpar@225 | 75 |
|
ladanyi@359 | 76 |
SET(CPACK_COMPONENT_HEADERS_INSTALL_TYPES Developer Full) |
ladanyi@359 | 77 |
SET(CPACK_COMPONENT_LIBRARY_INSTALL_TYPES Developer Full) |
ladanyi@359 | 78 |
SET(CPACK_COMPONENT_HTML_DOCUMENTATION_INSTALL_TYPES Full) |
alpar@225 | 79 |
|
alpar@225 | 80 |
SET(CPACK_GENERATOR "NSIS") |
alpar@225 | 81 |
SET(CPACK_NSIS_MUI_ICON "${CMAKE_SOURCE_DIR}/cmake/nsis/lemon.ico") |
alpar@225 | 82 |
SET(CPACK_NSIS_MUI_UNIICON "${CMAKE_SOURCE_DIR}/cmake/nsis/uninstall.ico") |
alpar@225 | 83 |
#SET(CPACK_PACKAGE_ICON "${CMAKE_SOURCE_DIR}/cmake/nsis\\\\installer.bmp") |
alpar@225 | 84 |
SET(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\\\lemon.ico") |
alpar@225 | 85 |
SET(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY} ${PROJECT_NAME}") |
alpar@225 | 86 |
SET(CPACK_NSIS_HELP_LINK "http:\\\\\\\\lemon.cs.elte.hu") |
alpar@225 | 87 |
SET(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\\\\\lemon.cs.elte.hu") |
alpar@225 | 88 |
SET(CPACK_NSIS_CONTACT "lemon-user@lemon.cs.elte.hu") |
alpar@225 | 89 |
SET(CPACK_NSIS_CREATE_ICONS_EXTRA " |
alpar@377 | 90 |
CreateShortCut \\\"$SMPROGRAMS\\\\$STARTMENU_FOLDER\\\\Documentation.lnk\\\" \\\"$INSTDIR\\\\share\\\\doc\\\\index.html\\\" |
alpar@225 | 91 |
") |
alpar@225 | 92 |
SET(CPACK_NSIS_DELETE_ICONS_EXTRA " |
alpar@225 | 93 |
!insertmacro MUI_STARTMENU_GETFOLDER Application $MUI_TEMP |
alpar@225 | 94 |
Delete \\\"$SMPROGRAMS\\\\$MUI_TEMP\\\\Documentation.lnk\\\" |
alpar@225 | 95 |
") |
alpar@225 | 96 |
|
alpar@225 | 97 |
INCLUDE(CPack) |
alpar@225 | 98 |
ENDIF(WIN32) |