cmake: generalize VERSION infrastructure for better reuse
Generalize the VERSION and version.h generation so that the same infrastructure can be reused for generating other version related header files, such as an application version header. Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
This commit is contained in:
parent
37c6136385
commit
2c757f9e7a
4 changed files with 103 additions and 73 deletions
|
@ -544,6 +544,8 @@ add_custom_command(
|
|||
OUTPUT ${PROJECT_BINARY_DIR}/include/generated/version.h
|
||||
COMMAND ${CMAKE_COMMAND} -DZEPHYR_BASE=${ZEPHYR_BASE}
|
||||
-DOUT_FILE=${PROJECT_BINARY_DIR}/include/generated/version.h
|
||||
-DVERSION_TYPE=KERNEL
|
||||
-DVERSION_FILE=${ZEPHYR_BASE}/VERSION
|
||||
${build_version_argument}
|
||||
-P ${ZEPHYR_BASE}/cmake/gen_version_h.cmake
|
||||
DEPENDS ${ZEPHYR_BASE}/VERSION ${git_dependency}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue