From 5d41d357ec5fad9462bc270926898a763b9d0dbf Mon Sep 17 00:00:00 2001 From: Pierre GRANDIN Date: Wed, 16 Sep 2015 20:37:36 -0700 Subject: Defaults to R0000 for builds outside of navit's official tree, fixes cmake error --- cmake/version.cmake | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'cmake') diff --git a/cmake/version.cmake b/cmake/version.cmake index ee419bbc4..8d08e5532 100644 --- a/cmake/version.cmake +++ b/cmake/version.cmake @@ -15,6 +15,11 @@ else() endif(GIT_EXECUTABLE) string(REGEX MATCH "R[0-9]+" VERSION_NUM ${VERSION} ) +if(NOT VERSION_NUM) + message(STATUS "I can't find a release tag. This is probably not Navit's official tree") + message(STATUS "It's OK, I will default to 0000") + set(VERSION_NUM "0000") +endif() string(REPLACE "R" "" VERSION_NUM ${VERSION_NUM} ) if(NOT VERSION_NUM) set(VERSION_NUM "0000") -- cgit v1.2.1