git.cmake: git describe --always to support shallow clones
There's no reason for BUILD_VERSION to work only when there are git tags. Signed-off-by: Marc Herbert <marc.herbert@intel.com>
This commit is contained in:
parent
654a2f245d
commit
4ea66b32fa
1 changed files with 1 additions and 1 deletions
|
@ -15,7 +15,7 @@
|
|||
find_package(Git QUIET)
|
||||
if(NOT BUILD_VERSION AND GIT_FOUND)
|
||||
execute_process(
|
||||
COMMAND ${GIT_EXECUTABLE} describe --abbrev=12
|
||||
COMMAND ${GIT_EXECUTABLE} describe --abbrev=12 --always
|
||||
WORKING_DIRECTORY ${ZEPHYR_BASE}
|
||||
OUTPUT_VARIABLE BUILD_VERSION
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue