This commit is contained in:
parent
b0810b80b7
commit
425a5524c4
1 changed files with 4 additions and 2 deletions
|
@ -6,7 +6,8 @@ execute_process(COMMAND bash "-c" "git rev-parse HEAD" OUTPUT_VARIABLE GIT_HASH
|
|||
execute_process(COMMAND bash "-c" "git tag -l --sort=refname 'v*' | tail -n1" OUTPUT_VARIABLE GIT_TAG OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
execute_process(COMMAND bash "-c" "git rev-list -n 1 ${GIT_TAG}" OUTPUT_VARIABLE GIT_TAG_HASH OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
message(STATUS "${GIT_HASH}")
|
||||
if(DEFINED RUN_PIPELINE)
|
||||
option(RUN_PIPELINE "" OFF)
|
||||
if(RUN_PIPELINE)
|
||||
set(VERSION "v0.0.0-test")
|
||||
else()
|
||||
message(STATUS "${GIT_TAG}")
|
||||
|
@ -17,7 +18,8 @@ else()
|
|||
set(VERSION "${VERSION}-${GIT_HASH_SHORT}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
message(STATUS "version = ${VERSION}")
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
if(NOT CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 7.0)
|
||||
message(FATAL_ERROR "require gcc version >= 7.0")
|
||||
|
|
Loading…
Reference in a new issue