mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-21 01:12:11 +00:00
cmake: fix update of git hashes
Since the git hashes were being generate by cmake it would only be
generated if the header file was not present. Simple test:
$ make aerofc-v1_default
$ touch a
$ git add a
$ git commit -m tmp
$ make aerofc-v1_default
The file build_aerofc-v1_default/build_git_version.h should have the new
hashes and the correspondent .c/c.pp files should be rebuilt, but they
aren't. The end result is that checking the version with "ver git" in
the nsh console will point to the wrong commit.
This moves the generation of the header to a separate tool and enforces
the command to be executed every time.
This commit is contained in:
committed by
Lorenz Meier
parent
8aede5d32b
commit
9ee478e1f7
@@ -448,7 +448,7 @@ endif()
|
||||
#=============================================================================
|
||||
# generate git version
|
||||
#
|
||||
px4_create_git_hash_header(HEADER ${PX4_BINARY_DIR}/build_git_version.h)
|
||||
px4_create_git_hash_header(OUT ${PX4_BINARY_DIR}/build_git_version.h)
|
||||
|
||||
#=============================================================================
|
||||
# packaging
|
||||
|
||||
Reference in New Issue
Block a user