Browse Source

Refactored version setting in CMake

tempestpy_adaptions
Matthias Volk 7 years ago
parent
commit
3f241280ea
  1. 12
      CMakeLists.txt

12
CMakeLists.txt

@ -398,20 +398,22 @@ else()
else() else()
set(STORM_VERSION_DIRTY "false") set(STORM_VERSION_DIRTY "false")
endif() endif()
endif()
set(STORM_VERSION_DEV_STRING "")
set(STORM_VERSION_DEV "false") set(STORM_VERSION_DEV "false")
set(STORM_VERSION_DEV_STRING "")
if(STORM_VERSION_COMMITS_AHEAD) if(STORM_VERSION_COMMITS_AHEAD)
MATH(EXPR STORM_VERSION_DEV_PATCH "${STORM_VERSION_PATCH}+1") MATH(EXPR STORM_VERSION_DEV_PATCH "${STORM_VERSION_PATCH}+1")
set(STORM_VERSION_DEV_STRING " (dev)")
set(STORM_VERSION_DEV "true") set(STORM_VERSION_DEV "true")
set(STORM_VERSION_DEV_STRING " (dev)")
else() else()
set(STORM_VERSION_DEV_PATCH ${STORM_VERSION_PATCH}) set(STORM_VERSION_DEV_PATCH ${STORM_VERSION_PATCH})
endif() endif()
message(STATUS "Storm - version is ${STORM_VERSION_MAJOR}.${STORM_VERSION_MINOR}.${STORM_VERSION_DEV_PATCH}${STORM_VERSION_DEV_STRING} (version ${STORM_VERSION_MAJOR}.${STORM_VERSION_MINOR}.${STORM_VERSION_PATCH} + ${STORM_VERSION_COMMITS_AHEAD} commits), building from git: ${STORM_VERSION_GIT_HASH} (dirty: ${STORM_VERSION_DIRTY}).")
endif()
set(STORM_VERSION "${STORM_VERSION_MAJOR}.${STORM_VERSION_MINOR}.${STORM_VERSION_DEV_PATCH}") set(STORM_VERSION "${STORM_VERSION_MAJOR}.${STORM_VERSION_MINOR}.${STORM_VERSION_DEV_PATCH}")
set(STORM_VERSION_STRING "${STORM_VERSION}${STORM_VERSION_DEV_STRING}")
message(STATUS "Storm - version is ${STORM_VERSION_STRING} (version ${STORM_VERSION_MAJOR}.${STORM_VERSION_MINOR}.${STORM_VERSION_PATCH} + ${STORM_VERSION_COMMITS_AHEAD} commits), building from git: ${STORM_VERSION_GIT_HASH} (dirty: ${STORM_VERSION_DIRTY}).")
# Configure a header file to pass some of the CMake settings to the source code # Configure a header file to pass some of the CMake settings to the source code

Loading…
Cancel
Save