Skip to content

Commit 041c2ef

Browse files
marc-hblgirdwood
authored andcommitted
version.cmake: add --dirty to git describe command
For at least two reasons: - exposes sneaky change(s) performed by automation if/when any - solves the mystery of the Source content hash (printed on the next line) changing while the git version does not. Example, at https://sof-ci.01.org/sofpr/PR3941/build8429/build/bdw_gcc.txt -- Found Git: /usr/bin/git (found version "2.17.1") -- GIT_TAG / GIT_LOG_HASH : v1.7-rc1-151-g023c4abacde1 / 023c4abac -- Source content hash: 91f261ea whereas at https://github.com/thesofproject/sof/runs/2166298087, xtensa-build-all: -- Found Git: /usr/bin/git (found version "2.17.1") -- GIT_TAG / GIT_LOG_HASH : v1.7-rc1-151-g023c4abacde1 / 023c4abac -- Source content hash: 67f31697 Signed-off-by: Marc Herbert <marc.herbert@intel.com>
1 parent 7e19c42 commit 041c2ef

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

scripts/cmake/version.cmake

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ if(EXISTS ${TARBALL_VERSION_SOURCE_PATH})
2323
list(GET lines 1 GIT_LOG_HASH)
2424
message(STATUS "Found ${TARBALL_VERSION_FILE_NAME}")
2525
else()
26-
execute_process(COMMAND git describe --tags --abbrev=12 --match v*
26+
execute_process(
27+
COMMAND git describe --tags --abbrev=12 --match v* --dirty
2728
WORKING_DIRECTORY ${SOF_ROOT_SOURCE_DIRECTORY}
2829
OUTPUT_VARIABLE GIT_TAG
2930
OUTPUT_STRIP_TRAILING_WHITESPACE

0 commit comments

Comments
 (0)