[1107] | 1 | CMAKE_MINIMUM_REQUIRED(VERSION 2.8) |
---|
[225] | 2 | |
---|
[1114] | 3 | CMAKE_POLICY(SET CMP0048 OLD) |
---|
| 4 | |
---|
[678] | 5 | SET(PROJECT_NAME "LEMON") |
---|
| 6 | PROJECT(${PROJECT_NAME}) |
---|
[225] | 7 | |
---|
[927] | 8 | INCLUDE(FindPythonInterp) |
---|
| 9 | INCLUDE(FindWget) |
---|
| 10 | |
---|
[678] | 11 | IF(EXISTS ${PROJECT_SOURCE_DIR}/cmake/version.cmake) |
---|
| 12 | INCLUDE(${PROJECT_SOURCE_DIR}/cmake/version.cmake) |
---|
| 13 | ELSEIF(DEFINED ENV{LEMON_VERSION}) |
---|
| 14 | SET(LEMON_VERSION $ENV{LEMON_VERSION} CACHE STRING "LEMON version string.") |
---|
| 15 | ELSE() |
---|
| 16 | EXECUTE_PROCESS( |
---|
[982] | 17 | COMMAND |
---|
| 18 | hg log -r. --template "{latesttag}" |
---|
[927] | 19 | WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} |
---|
[982] | 20 | OUTPUT_VARIABLE HG_REVISION_TAG |
---|
[927] | 21 | ERROR_QUIET |
---|
| 22 | OUTPUT_STRIP_TRAILING_WHITESPACE |
---|
| 23 | ) |
---|
| 24 | EXECUTE_PROCESS( |
---|
[982] | 25 | COMMAND |
---|
| 26 | hg log -r. --template "{latesttagdistance}" |
---|
[678] | 27 | WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} |
---|
[982] | 28 | OUTPUT_VARIABLE HG_REVISION_DIST |
---|
[678] | 29 | ERROR_QUIET |
---|
| 30 | OUTPUT_STRIP_TRAILING_WHITESPACE |
---|
| 31 | ) |
---|
[982] | 32 | EXECUTE_PROCESS( |
---|
| 33 | COMMAND |
---|
| 34 | hg log -r. --template "{node|short}" |
---|
| 35 | WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} |
---|
| 36 | OUTPUT_VARIABLE HG_REVISION_ID |
---|
| 37 | ERROR_QUIET |
---|
| 38 | OUTPUT_STRIP_TRAILING_WHITESPACE |
---|
| 39 | ) |
---|
| 40 | |
---|
| 41 | IF(HG_REVISION_TAG STREQUAL "") |
---|
[927] | 42 | SET(HG_REVISION_ID "hg-tip") |
---|
| 43 | ELSE() |
---|
[982] | 44 | IF(HG_REVISION_TAG STREQUAL "null") |
---|
| 45 | SET(HG_REVISION_TAG "trunk") |
---|
| 46 | ELSEIF(HG_REVISION_TAG MATCHES "^r") |
---|
| 47 | STRING(SUBSTRING ${HG_REVISION_TAG} 1 -1 HG_REVISION_TAG) |
---|
| 48 | ENDIF() |
---|
| 49 | IF(HG_REVISION_DIST STREQUAL "0") |
---|
| 50 | SET(HG_REVISION ${HG_REVISION_TAG}) |
---|
[927] | 51 | ELSE() |
---|
[982] | 52 | SET(HG_REVISION |
---|
| 53 | "${HG_REVISION_TAG}+${HG_REVISION_DIST}-${HG_REVISION_ID}") |
---|
[927] | 54 | ENDIF() |
---|
[680] | 55 | ENDIF() |
---|
[982] | 56 | |
---|
| 57 | SET(LEMON_VERSION ${HG_REVISION} CACHE STRING "LEMON version string.") |
---|
[678] | 58 | ENDIF() |
---|
| 59 | |
---|
| 60 | SET(PROJECT_VERSION ${LEMON_VERSION}) |
---|
[225] | 61 | |
---|
[549] | 62 | SET(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) |
---|
[225] | 63 | |
---|
[679] | 64 | FIND_PACKAGE(Doxygen) |
---|
| 65 | FIND_PACKAGE(Ghostscript) |
---|
[1064] | 66 | |
---|
| 67 | SET(LEMON_ENABLE_GLPK YES CACHE STRING "Enable GLPK solver backend.") |
---|
| 68 | SET(LEMON_ENABLE_ILOG YES CACHE STRING "Enable ILOG (CPLEX) solver backend.") |
---|
| 69 | SET(LEMON_ENABLE_COIN YES CACHE STRING "Enable COIN solver backend.") |
---|
[1088] | 70 | SET(LEMON_ENABLE_SOPLEX YES CACHE STRING "Enable SoPlex solver backend.") |
---|
[1064] | 71 | |
---|
| 72 | IF(LEMON_ENABLE_GLPK) |
---|
| 73 | FIND_PACKAGE(GLPK 4.33) |
---|
| 74 | ENDIF(LEMON_ENABLE_GLPK) |
---|
| 75 | IF(LEMON_ENABLE_ILOG) |
---|
| 76 | FIND_PACKAGE(ILOG) |
---|
| 77 | ENDIF(LEMON_ENABLE_ILOG) |
---|
| 78 | IF(LEMON_ENABLE_COIN) |
---|
| 79 | FIND_PACKAGE(COIN) |
---|
| 80 | ENDIF(LEMON_ENABLE_COIN) |
---|
[1088] | 81 | IF(LEMON_ENABLE_SOPLEX) |
---|
| 82 | FIND_PACKAGE(SOPLEX) |
---|
| 83 | ENDIF(LEMON_ENABLE_SOPLEX) |
---|
[1064] | 84 | |
---|
| 85 | IF(GLPK_FOUND) |
---|
| 86 | SET(LEMON_HAVE_LP TRUE) |
---|
| 87 | SET(LEMON_HAVE_MIP TRUE) |
---|
| 88 | SET(LEMON_HAVE_GLPK TRUE) |
---|
| 89 | ENDIF(GLPK_FOUND) |
---|
| 90 | IF(ILOG_FOUND) |
---|
| 91 | SET(LEMON_HAVE_LP TRUE) |
---|
| 92 | SET(LEMON_HAVE_MIP TRUE) |
---|
[1066] | 93 | SET(LEMON_HAVE_CPLEX TRUE) |
---|
[1064] | 94 | ENDIF(ILOG_FOUND) |
---|
| 95 | IF(COIN_FOUND) |
---|
| 96 | SET(LEMON_HAVE_LP TRUE) |
---|
| 97 | SET(LEMON_HAVE_MIP TRUE) |
---|
| 98 | SET(LEMON_HAVE_CLP TRUE) |
---|
| 99 | SET(LEMON_HAVE_CBC TRUE) |
---|
| 100 | ENDIF(COIN_FOUND) |
---|
[1088] | 101 | IF(SOPLEX_FOUND) |
---|
| 102 | SET(LEMON_HAVE_LP TRUE) |
---|
| 103 | SET(LEMON_HAVE_SOPLEX TRUE) |
---|
| 104 | ENDIF(SOPLEX_FOUND) |
---|
[1064] | 105 | |
---|
| 106 | IF(ILOG_FOUND) |
---|
| 107 | SET(DEFAULT_LP "CPLEX") |
---|
| 108 | SET(DEFAULT_MIP "CPLEX") |
---|
| 109 | ELSEIF(COIN_FOUND) |
---|
| 110 | SET(DEFAULT_LP "CLP") |
---|
| 111 | SET(DEFAULT_MIP "CBC") |
---|
| 112 | ELSEIF(GLPK_FOUND) |
---|
| 113 | SET(DEFAULT_LP "GLPK") |
---|
| 114 | SET(DEFAULT_MIP "GLPK") |
---|
[1088] | 115 | ELSEIF(SOPLEX_FOUND) |
---|
| 116 | SET(DEFAULT_LP "SOPLEX") |
---|
[1064] | 117 | ENDIF() |
---|
| 118 | |
---|
| 119 | IF(NOT LEMON_DEFAULT_LP OR |
---|
| 120 | (NOT ILOG_FOUND AND (LEMON_DEFAULT_LP STREQUAL "CPLEX")) OR |
---|
| 121 | (NOT COIN_FOUND AND (LEMON_DEFAULT_LP STREQUAL "CLP")) OR |
---|
[1088] | 122 | (NOT GLPK_FOUND AND (LEMON_DEFAULT_LP STREQUAL "GLPK")) OR |
---|
| 123 | (NOT SOPLEX_FOUND AND (LEMON_DEFAULT_LP STREQUAL "SOPLEX"))) |
---|
[1064] | 124 | SET(LEMON_DEFAULT_LP ${DEFAULT_LP} CACHE STRING |
---|
[1088] | 125 | "Default LP solver backend (GLPK, CPLEX, CLP or SOPLEX)" FORCE) |
---|
[1105] | 126 | ELSE() |
---|
| 127 | SET(LEMON_DEFAULT_LP ${DEFAULT_LP} CACHE STRING |
---|
| 128 | "Default LP solver backend (GLPK, CPLEX, CLP or SOPLEX)") |
---|
[1064] | 129 | ENDIF() |
---|
| 130 | IF(NOT LEMON_DEFAULT_MIP OR |
---|
| 131 | (NOT ILOG_FOUND AND (LEMON_DEFAULT_MIP STREQUAL "CPLEX")) OR |
---|
| 132 | (NOT COIN_FOUND AND (LEMON_DEFAULT_MIP STREQUAL "CBC")) OR |
---|
| 133 | (NOT GLPK_FOUND AND (LEMON_DEFAULT_MIP STREQUAL "GLPK"))) |
---|
| 134 | SET(LEMON_DEFAULT_MIP ${DEFAULT_MIP} CACHE STRING |
---|
| 135 | "Default MIP solver backend (GLPK, CPLEX or CBC)" FORCE) |
---|
[1105] | 136 | ELSE() |
---|
| 137 | SET(LEMON_DEFAULT_MIP ${DEFAULT_MIP} CACHE STRING |
---|
| 138 | "Default MIP solver backend (GLPK, CPLEX or CBC)") |
---|
[1064] | 139 | ENDIF() |
---|
| 140 | |
---|
[473] | 141 | |
---|
[927] | 142 | IF(DEFINED ENV{LEMON_CXX_WARNING}) |
---|
| 143 | SET(CXX_WARNING $ENV{LEMON_CXX_WARNING}) |
---|
| 144 | ELSE() |
---|
| 145 | IF(CMAKE_COMPILER_IS_GNUCXX) |
---|
[940] | 146 | SET(CXX_WARNING "-Wall -W -Wunused -Wformat=2 -Wctor-dtor-privacy -Wnon-virtual-dtor -Wno-char-subscripts -Wwrite-strings -Wno-char-subscripts -Wreturn-type -Wcast-qual -Wcast-align -Wsign-promo -Woverloaded-virtual -fno-strict-aliasing -Wold-style-cast -Wno-unknown-pragmas") |
---|
[927] | 147 | SET(CMAKE_CXX_FLAGS_DEBUG CACHE STRING "-ggdb") |
---|
| 148 | SET(CMAKE_C_FLAGS_DEBUG CACHE STRING "-ggdb") |
---|
| 149 | ELSEIF(MSVC) |
---|
| 150 | # This part is unnecessary 'casue the same is set by the lemon/core.h. |
---|
| 151 | # Still keep it as an example. |
---|
| 152 | SET(CXX_WARNING "/wd4250 /wd4355 /wd4503 /wd4800 /wd4996") |
---|
| 153 | # Suppressed warnings: |
---|
| 154 | # C4250: 'class1' : inherits 'class2::member' via dominance |
---|
| 155 | # C4355: 'this' : used in base member initializer list |
---|
| 156 | # C4503: 'function' : decorated name length exceeded, name was truncated |
---|
| 157 | # C4800: 'type' : forcing value to bool 'true' or 'false' |
---|
| 158 | # (performance warning) |
---|
| 159 | # C4996: 'function': was declared deprecated |
---|
| 160 | ELSE() |
---|
[975] | 161 | SET(CXX_WARNING "-Wall") |
---|
[927] | 162 | ENDIF() |
---|
| 163 | ENDIF() |
---|
| 164 | SET(LEMON_CXX_WARNING_FLAGS ${CXX_WARNING} CACHE STRING "LEMON warning flags.") |
---|
| 165 | |
---|
| 166 | SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${LEMON_CXX_WARNING_FLAGS}") |
---|
| 167 | |
---|
[1017] | 168 | IF(MSVC) |
---|
| 169 | SET( CMAKE_CXX_FLAGS_MAINTAINER "/WX ${CMAKE_CXX_FLAGS_DEBUG}" CACHE STRING |
---|
[927] | 170 | "Flags used by the C++ compiler during maintainer builds." |
---|
[1017] | 171 | ) |
---|
| 172 | SET( CMAKE_C_FLAGS_MAINTAINER "/WX ${CMAKE_CXX_FLAGS_DEBUG}" CACHE STRING |
---|
[927] | 173 | "Flags used by the C compiler during maintainer builds." |
---|
[1017] | 174 | ) |
---|
| 175 | SET( CMAKE_EXE_LINKER_FLAGS_MAINTAINER |
---|
| 176 | "${CMAKE_EXE_LINKER_FLAGS_DEBUG}" CACHE STRING |
---|
| 177 | "Flags used for linking binaries during maintainer builds." |
---|
| 178 | ) |
---|
| 179 | SET( CMAKE_SHARED_LINKER_FLAGS_MAINTAINER |
---|
| 180 | "${CMAKE_SHARED_LINKER_FLAGS_DEBUG}" CACHE STRING |
---|
| 181 | "Flags used by the shared libraries linker during maintainer builds." |
---|
| 182 | ) |
---|
| 183 | ELSE() |
---|
| 184 | SET( CMAKE_CXX_FLAGS_MAINTAINER "-Werror -ggdb -O0" CACHE STRING |
---|
| 185 | "Flags used by the C++ compiler during maintainer builds." |
---|
| 186 | ) |
---|
| 187 | SET( CMAKE_C_FLAGS_MAINTAINER "-Werror -O0" CACHE STRING |
---|
| 188 | "Flags used by the C compiler during maintainer builds." |
---|
| 189 | ) |
---|
| 190 | SET( CMAKE_EXE_LINKER_FLAGS_MAINTAINER |
---|
[1111] | 191 | "${CMAKE_EXE_LINKER_FLAGS_DEBUG}" CACHE STRING |
---|
[927] | 192 | "Flags used for linking binaries during maintainer builds." |
---|
[1017] | 193 | ) |
---|
| 194 | SET( CMAKE_SHARED_LINKER_FLAGS_MAINTAINER |
---|
[1111] | 195 | "${CMAKE_SHARED_LINKER_FLAGS_DEBUG}" CACHE STRING |
---|
[927] | 196 | "Flags used by the shared libraries linker during maintainer builds." |
---|
[1017] | 197 | ) |
---|
| 198 | ENDIF() |
---|
| 199 | |
---|
[927] | 200 | MARK_AS_ADVANCED( |
---|
| 201 | CMAKE_CXX_FLAGS_MAINTAINER |
---|
| 202 | CMAKE_C_FLAGS_MAINTAINER |
---|
| 203 | CMAKE_EXE_LINKER_FLAGS_MAINTAINER |
---|
| 204 | CMAKE_SHARED_LINKER_FLAGS_MAINTAINER ) |
---|
| 205 | |
---|
| 206 | IF(CMAKE_CONFIGURATION_TYPES) |
---|
| 207 | LIST(APPEND CMAKE_CONFIGURATION_TYPES Maintainer) |
---|
| 208 | LIST(REMOVE_DUPLICATES CMAKE_CONFIGURATION_TYPES) |
---|
| 209 | SET(CMAKE_CONFIGURATION_TYPES "${CMAKE_CONFIGURATION_TYPES}" CACHE STRING |
---|
| 210 | "Add the configurations that we need" |
---|
| 211 | FORCE) |
---|
| 212 | endif() |
---|
| 213 | |
---|
| 214 | IF(NOT CMAKE_BUILD_TYPE) |
---|
| 215 | SET(CMAKE_BUILD_TYPE "Release") |
---|
| 216 | ENDIF() |
---|
| 217 | |
---|
| 218 | SET( CMAKE_BUILD_TYPE "${CMAKE_BUILD_TYPE}" CACHE STRING |
---|
| 219 | "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel Maintainer." |
---|
| 220 | FORCE ) |
---|
| 221 | |
---|
| 222 | |
---|
[496] | 223 | INCLUDE(CheckTypeSize) |
---|
[677] | 224 | CHECK_TYPE_SIZE("long long" LONG_LONG) |
---|
| 225 | SET(LEMON_HAVE_LONG_LONG ${HAVE_LONG_LONG}) |
---|
[496] | 226 | |
---|
[979] | 227 | INCLUDE(FindThreads) |
---|
[980] | 228 | |
---|
| 229 | IF(NOT LEMON_THREADING) |
---|
| 230 | IF(CMAKE_USE_PTHREADS_INIT) |
---|
| 231 | SET(LEMON_THREADING "Pthread") |
---|
| 232 | ELSEIF(CMAKE_USE_WIN32_THREADS_INIT) |
---|
| 233 | SET(LEMON_THREADING "Win32") |
---|
| 234 | ELSE() |
---|
| 235 | SET(LEMON_THREADING "None") |
---|
| 236 | ENDIF() |
---|
| 237 | ENDIF() |
---|
| 238 | |
---|
| 239 | SET( LEMON_THREADING "${LEMON_THREADING}" CACHE STRING |
---|
| 240 | "Choose the threading library, options are: Pthread Win32 None." |
---|
| 241 | FORCE ) |
---|
| 242 | |
---|
| 243 | IF(LEMON_THREADING STREQUAL "Pthread") |
---|
| 244 | SET(LEMON_USE_PTHREAD TRUE) |
---|
| 245 | ELSEIF(LEMON_THREADING STREQUAL "Win32") |
---|
| 246 | SET(LEMON_USE_WIN32_THREADS TRUE) |
---|
| 247 | ENDIF() |
---|
[744] | 248 | |
---|
[225] | 249 | ENABLE_TESTING() |
---|
| 250 | |
---|
[927] | 251 | IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer") |
---|
| 252 | ADD_CUSTOM_TARGET(check ALL COMMAND ${CMAKE_CTEST_COMMAND}) |
---|
| 253 | ELSE() |
---|
| 254 | ADD_CUSTOM_TARGET(check COMMAND ${CMAKE_CTEST_COMMAND}) |
---|
| 255 | ENDIF() |
---|
| 256 | |
---|
[225] | 257 | ADD_SUBDIRECTORY(lemon) |
---|
[549] | 258 | IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR}) |
---|
[925] | 259 | ADD_SUBDIRECTORY(contrib) |
---|
[549] | 260 | ADD_SUBDIRECTORY(demo) |
---|
| 261 | ADD_SUBDIRECTORY(tools) |
---|
| 262 | ADD_SUBDIRECTORY(doc) |
---|
| 263 | ADD_SUBDIRECTORY(test) |
---|
[679] | 264 | ENDIF() |
---|
[225] | 265 | |
---|
[675] | 266 | CONFIGURE_FILE( |
---|
| 267 | ${PROJECT_SOURCE_DIR}/cmake/LEMONConfig.cmake.in |
---|
| 268 | ${PROJECT_BINARY_DIR}/cmake/LEMONConfig.cmake |
---|
| 269 | @ONLY |
---|
| 270 | ) |
---|
| 271 | IF(UNIX) |
---|
| 272 | INSTALL( |
---|
| 273 | FILES ${PROJECT_BINARY_DIR}/cmake/LEMONConfig.cmake |
---|
| 274 | DESTINATION share/lemon/cmake |
---|
| 275 | ) |
---|
| 276 | ELSEIF(WIN32) |
---|
| 277 | INSTALL( |
---|
| 278 | FILES ${PROJECT_BINARY_DIR}/cmake/LEMONConfig.cmake |
---|
| 279 | DESTINATION cmake |
---|
| 280 | ) |
---|
[679] | 281 | ENDIF() |
---|
[675] | 282 | |
---|
[983] | 283 | CONFIGURE_FILE( |
---|
| 284 | ${PROJECT_SOURCE_DIR}/cmake/version.cmake.in |
---|
| 285 | ${PROJECT_BINARY_DIR}/cmake/version.cmake |
---|
| 286 | @ONLY |
---|
| 287 | ) |
---|
| 288 | |
---|
| 289 | SET(ARCHIVE_BASE_NAME ${CMAKE_PROJECT_NAME}) |
---|
| 290 | STRING(TOLOWER ${ARCHIVE_BASE_NAME} ARCHIVE_BASE_NAME) |
---|
| 291 | SET(ARCHIVE_NAME ${ARCHIVE_BASE_NAME}-${PROJECT_VERSION}) |
---|
| 292 | ADD_CUSTOM_TARGET(dist |
---|
| 293 | COMMAND cmake -E remove_directory ${ARCHIVE_NAME} |
---|
| 294 | COMMAND hg archive ${ARCHIVE_NAME} |
---|
| 295 | COMMAND cmake -E copy cmake/version.cmake ${ARCHIVE_NAME}/cmake/version.cmake |
---|
| 296 | COMMAND tar -czf ${ARCHIVE_BASE_NAME}-nodoc-${PROJECT_VERSION}.tar.gz ${ARCHIVE_NAME} |
---|
| 297 | COMMAND zip -r ${ARCHIVE_BASE_NAME}-nodoc-${PROJECT_VERSION}.zip ${ARCHIVE_NAME} |
---|
| 298 | COMMAND cmake -E copy_directory doc/html ${ARCHIVE_NAME}/doc/html |
---|
| 299 | COMMAND tar -czf ${ARCHIVE_NAME}.tar.gz ${ARCHIVE_NAME} |
---|
| 300 | COMMAND zip -r ${ARCHIVE_NAME}.zip ${ARCHIVE_NAME} |
---|
| 301 | COMMAND cmake -E copy_directory doc/html ${ARCHIVE_BASE_NAME}-doc-${PROJECT_VERSION} |
---|
| 302 | COMMAND tar -czf ${ARCHIVE_BASE_NAME}-doc-${PROJECT_VERSION}.tar.gz ${ARCHIVE_BASE_NAME}-doc-${PROJECT_VERSION} |
---|
| 303 | COMMAND zip -r ${ARCHIVE_BASE_NAME}-doc-${PROJECT_VERSION}.zip ${ARCHIVE_BASE_NAME}-doc-${PROJECT_VERSION} |
---|
| 304 | COMMAND cmake -E remove_directory ${ARCHIVE_NAME} |
---|
| 305 | COMMAND cmake -E remove_directory ${ARCHIVE_BASE_NAME}-doc-${PROJECT_VERSION} |
---|
| 306 | DEPENDS html |
---|
| 307 | WORKING_DIRECTORY ${PROJECT_BINARY_DIR}) |
---|
| 308 | |
---|
| 309 | # CPACK config (Basically for NSIS) |
---|
[927] | 310 | IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR}) |
---|
[679] | 311 | SET(CPACK_PACKAGE_NAME ${PROJECT_NAME}) |
---|
| 312 | SET(CPACK_PACKAGE_VENDOR "EGRES") |
---|
| 313 | SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY |
---|
| 314 | "LEMON - Library for Efficient Modeling and Optimization in Networks") |
---|
| 315 | SET(CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/LICENSE") |
---|
[225] | 316 | |
---|
[679] | 317 | SET(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) |
---|
[225] | 318 | |
---|
[679] | 319 | SET(CPACK_PACKAGE_INSTALL_DIRECTORY |
---|
| 320 | "${PROJECT_NAME} ${PROJECT_VERSION}") |
---|
| 321 | SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY |
---|
| 322 | "${PROJECT_NAME} ${PROJECT_VERSION}") |
---|
[225] | 323 | |
---|
[679] | 324 | SET(CPACK_COMPONENTS_ALL headers library html_documentation bin) |
---|
[225] | 325 | |
---|
[679] | 326 | SET(CPACK_COMPONENT_HEADERS_DISPLAY_NAME "C++ headers") |
---|
| 327 | SET(CPACK_COMPONENT_LIBRARY_DISPLAY_NAME "Dynamic-link library") |
---|
| 328 | SET(CPACK_COMPONENT_BIN_DISPLAY_NAME "Command line utilities") |
---|
| 329 | SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DISPLAY_NAME "HTML documentation") |
---|
[225] | 330 | |
---|
[679] | 331 | SET(CPACK_COMPONENT_HEADERS_DESCRIPTION |
---|
| 332 | "C++ header files") |
---|
| 333 | SET(CPACK_COMPONENT_LIBRARY_DESCRIPTION |
---|
| 334 | "DLL and import library") |
---|
| 335 | SET(CPACK_COMPONENT_BIN_DESCRIPTION |
---|
| 336 | "Command line utilities") |
---|
| 337 | SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DESCRIPTION |
---|
| 338 | "Doxygen generated documentation") |
---|
[225] | 339 | |
---|
[679] | 340 | SET(CPACK_COMPONENT_HEADERS_DEPENDS library) |
---|
[225] | 341 | |
---|
[679] | 342 | SET(CPACK_COMPONENT_HEADERS_GROUP "Development") |
---|
| 343 | SET(CPACK_COMPONENT_LIBRARY_GROUP "Development") |
---|
| 344 | SET(CPACK_COMPONENT_HTML_DOCUMENTATION_GROUP "Documentation") |
---|
[225] | 345 | |
---|
[679] | 346 | SET(CPACK_COMPONENT_GROUP_DEVELOPMENT_DESCRIPTION |
---|
| 347 | "Components needed to develop software using LEMON") |
---|
| 348 | SET(CPACK_COMPONENT_GROUP_DOCUMENTATION_DESCRIPTION |
---|
| 349 | "Documentation of LEMON") |
---|
[225] | 350 | |
---|
[679] | 351 | SET(CPACK_ALL_INSTALL_TYPES Full Developer) |
---|
[225] | 352 | |
---|
[679] | 353 | SET(CPACK_COMPONENT_HEADERS_INSTALL_TYPES Developer Full) |
---|
| 354 | SET(CPACK_COMPONENT_LIBRARY_INSTALL_TYPES Developer Full) |
---|
| 355 | SET(CPACK_COMPONENT_HTML_DOCUMENTATION_INSTALL_TYPES Full) |
---|
[225] | 356 | |
---|
[679] | 357 | SET(CPACK_GENERATOR "NSIS") |
---|
| 358 | SET(CPACK_NSIS_MUI_ICON "${PROJECT_SOURCE_DIR}/cmake/nsis/lemon.ico") |
---|
| 359 | SET(CPACK_NSIS_MUI_UNIICON "${PROJECT_SOURCE_DIR}/cmake/nsis/uninstall.ico") |
---|
| 360 | #SET(CPACK_PACKAGE_ICON "${PROJECT_SOURCE_DIR}/cmake/nsis\\\\installer.bmp") |
---|
| 361 | SET(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\\\lemon.ico") |
---|
| 362 | SET(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY} ${PROJECT_NAME}") |
---|
| 363 | SET(CPACK_NSIS_HELP_LINK "http:\\\\\\\\lemon.cs.elte.hu") |
---|
| 364 | SET(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\\\\\lemon.cs.elte.hu") |
---|
| 365 | SET(CPACK_NSIS_CONTACT "lemon-user@lemon.cs.elte.hu") |
---|
| 366 | SET(CPACK_NSIS_CREATE_ICONS_EXTRA " |
---|
| 367 | CreateShortCut \\\"$SMPROGRAMS\\\\$STARTMENU_FOLDER\\\\Documentation.lnk\\\" \\\"$INSTDIR\\\\share\\\\doc\\\\index.html\\\" |
---|
| 368 | ") |
---|
| 369 | SET(CPACK_NSIS_DELETE_ICONS_EXTRA " |
---|
| 370 | !insertmacro MUI_STARTMENU_GETFOLDER Application $MUI_TEMP |
---|
| 371 | Delete \\\"$SMPROGRAMS\\\\$MUI_TEMP\\\\Documentation.lnk\\\" |
---|
| 372 | ") |
---|
[225] | 373 | |
---|
[679] | 374 | INCLUDE(CPack) |
---|
| 375 | ENDIF() |
---|