From 6a047088cb26248ec783713bb94925638aad8552 Mon Sep 17 00:00:00 2001 From: Manuel Bentele Date: Wed, 17 Mar 2021 09:04:04 +0100 Subject: [BUILD] Fix build issue if version information (Git tag) is missing The software version for packaging purposes is consituted from the following rules: - If the version information (from Git tags or the embedded version header file) is available, the version number for the packaging is set to those found version information. - If there isn't any version information available (e.g. missing Git tags), the version number for the packaging is set to '0.0' to represent an unkown version number. --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index fb4d5d1..bb613df 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -122,7 +122,7 @@ endif(DNBD3_RELEASE_HARDEN AND CMAKE_BUILD_TYPE MATCHES "Release") # define packaging if Release build is enabled if(CMAKE_BUILD_TYPE MATCHES Release) # get version source package or Git repository - get_repository_version(REPOSITORY_VERSION ${INCLUDE_VERSION_HEADER} ${CMAKE_BUILD_TYPE} ${GIT_EXECUTABLE} ${CMAKE_SOURCE_DIR}) + get_repository_version(REPOSITORY_VERSION REPOSITORY_BRANCH ${INCLUDE_VERSION_HEADER} ${CMAKE_BUILD_TYPE} ${GIT_EXECUTABLE} ${CMAKE_SOURCE_DIR}) # define project version if(KernelHeaders_VERSION) -- cgit v1.2.3-55-g7522