cmake: Fix dependencies so builds are sparse again
In cmake we use target_byproducts() to register dependence on the map file alongside the executable for it - this makes sense. Thus if the map file is missing, ninja will detect and issue a linker command again. However after that, cmake was instructed to rename the map file. Thus a 2nd round of ninja, which should be a no-op, is not as the registered byproduct file is missing. To keep this static, and to keep the map file alongside the elf file, we will instead copy the map file. Signed-off-by: Mark Ruvald Pedersen <mped@oticon.com>
This commit is contained in:
parent
82ac3fa079
commit
d8df801fe4
1 changed files with 1 additions and 1 deletions
|
@ -1405,7 +1405,7 @@ set(post_build_byproducts "")
|
|||
list(APPEND
|
||||
post_build_commands
|
||||
COMMAND
|
||||
${CMAKE_COMMAND} -E rename ${logical_target_for_zephyr_elf}.map ${KERNEL_MAP_NAME}
|
||||
${CMAKE_COMMAND} -E copy ${logical_target_for_zephyr_elf}.map ${KERNEL_MAP_NAME}
|
||||
)
|
||||
list(APPEND post_build_byproducts ${KERNEL_MAP_NAME})
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue