summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Clegg <sbc@chromium.org>2020-01-23 16:39:01 -0800
committerAlon Zakai <azakai@google.com>2020-01-23 16:39:01 -0800
commitdbb33e7dcc514b19bf91518f47fa46a47cd484a3 (patch)
tree9b1f0af1abf0eee8fb96a82716f6cb79e9d0d927
parenta74e9cd840e70cf6350b0c0d971a4316e7c3ee9e (diff)
downloadbinaryen-dbb33e7dcc514b19bf91518f47fa46a47cd484a3.tar.gz
binaryen-dbb33e7dcc514b19bf91518f47fa46a47cd484a3.tar.bz2
binaryen-dbb33e7dcc514b19bf91518f47fa46a47cd484a3.zip
Don't error out if `git describe` fails (#2618)
This can occurs in a shallow clone for example that doesn't have any version tags in its history. This is happening on travis CI which is causing the builds to fail since travis uses `--depth=50` when it clones. Fixes #2617
-rw-r--r--CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index cb771e257..4efd24c85 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -22,7 +22,7 @@ if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/.git)
GIT_VERSION
OUTPUT_STRIP_TRAILING_WHITESPACE)
if(${GIT_VERSION_RESULT})
- message(FATAL_ERROR "Error running git describe to determine version")
+ message(WARNING "Error running git describe to determine version")
else()
set(CMAKE_PROJECT_VERSION "${CMAKE_PROJECT_VERSION} (${GIT_VERSION})")
endif()