CMake: hand off RC-or-not to the version header again (for welcome-checks)

This commit is contained in:
Adriaan de Groot 2022-04-20 13:01:39 +02:00
parent 15b4660d3e
commit 1101b0dc82

View File

@ -530,10 +530,10 @@ if(NOT BUILD_RELEASE AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/.git/")
extend_version( "${CALAMARES_VERSION}" OFF CALAMARES_VERSION_SHORT CALAMARES_VERSION ) extend_version( "${CALAMARES_VERSION}" OFF CALAMARES_VERSION_SHORT CALAMARES_VERSION )
endif() endif()
# Special target for not-RC (e.g. might-be-release) builds. # Special define for RC (e.g. not-a-release) builds.
# This is used by the release script to get the version. # This is consumed via the CalamaresConfig.h header.
if(CALAMARES_VERSION_RC EQUAL 0) if(NOT CALAMARES_RELEASE_MODE)
add_custom_target(show-version ${CMAKE_COMMAND} -E echo CALAMARES_VERSION=${CALAMARES_VERSION_SHORT} USES_TERMINAL) set(CALAMARES_VERSION_RC 1)
endif() endif()
# enforce using constBegin, constEnd for const-iterators # enforce using constBegin, constEnd for const-iterators