From 4edb7f26ace10934cc570b4236f3b4fa88d56790 Mon Sep 17 00:00:00 2001 From: mlangkabel Date: Fri, 1 Feb 2019 15:43:16 +0100 Subject: [PATCH] fix build issue if tags of this repo are not checked out (issue #1) --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index d1c4c7a..a4f85e3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -32,6 +32,11 @@ if(EXISTS "${CMAKE_SOURCE_DIR}/.git") OUTPUT_STRIP_TRAILING_WHITESPACE ) else() + set(GIT_VERSION_NUMBER "") +endif() + +if("${GIT_VERSION_NUMBER}" STREQUAL "") + message(WARNING "Unable to derive SourcetrailDB version number from most recent Git tag.") set(GIT_VERSION_NUMBER "v0.db0.p0-0-a") endif()