Skip to content

Commit

Permalink
ROMFS/CMakeLists.txt: Fix dependency for rc.sysinit (again)
Browse files Browse the repository at this point in the history
Prior to this patch rc.sysinit was always rebuilt unconditionally, this
rule stops that.
  • Loading branch information
pussuw committed Dec 20, 2024
1 parent 8bca9a8 commit d190ac9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ROMFS/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -142,15 +142,16 @@ set(extras_dependencies)

# sysinit script for kernel mode
if(CONFIG_BUILD_KERNEL)
add_custom_command(OUTPUT ${romfs_gen_root_dir}/init.d/rc.sysinit
add_custom_command(OUTPUT ${romfs_gen_root_dir}/init.d/rc.sysinit rc.sysinit.stamp
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${PX4_BINARY_DIR}/NuttX/rc.sysinit ${romfs_gen_root_dir}/init.d/rc.sysinit
COMMAND ${CMAKE_COMMAND} -E touch rc.sysinit.stamp
DEPENDS
${PX4_BINARY_DIR}/NuttX/rc.sysinit
romfs_copy.stamp
COMMENT "ROMFS: copying rc.sysinit"
)
list(APPEND extras_dependencies
${romfs_gen_root_dir}/init.d/rc.sysinit
rc.sysinit.stamp
)
endif()

Expand Down

0 comments on commit d190ac9

Please sign in to comment.