mirror of
https://github.com/apache/nuttx.git
synced 2026-08-17 02:13:19 +00:00
cmake(bugfix):fix common/etc confilt with src/etc in CMake genromfs
We use the rules added later to overwrite the previous rules Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
This commit is contained in:
parent
4f80953ecd
commit
e3fcb025cb
1 changed files with 7 additions and 1 deletions
|
|
@ -341,12 +341,18 @@ function(process_all_directory_romfs)
|
|||
DEPENDS ${dyn_deps})
|
||||
list(APPEND DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${SOURCE_ETC_SUFFIX})
|
||||
else()
|
||||
list(FIND DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${SOURCE_ETC_SUFFIX} index)
|
||||
if(index GREATER -1)
|
||||
set(APPEND_OPTION APPEND)
|
||||
else()
|
||||
set(APPEND_OPTION)
|
||||
endif()
|
||||
list(APPEND DEPENDS ${SOURCE_ETC_PREFIX}/${SOURCE_ETC_SUFFIX})
|
||||
add_custom_command(
|
||||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${SOURCE_ETC_SUFFIX}
|
||||
COMMAND
|
||||
${CMAKE_COMMAND} -E copy ${SOURCE_ETC_PREFIX}/${SOURCE_ETC_SUFFIX}
|
||||
${CMAKE_CURRENT_BINARY_DIR}/${SOURCE_ETC_SUFFIX}
|
||||
${CMAKE_CURRENT_BINARY_DIR}/${SOURCE_ETC_SUFFIX} ${APPEND_OPTION}
|
||||
DEPENDS ${dyn_deps})
|
||||
list(APPEND DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${SOURCE_ETC_SUFFIX})
|
||||
endif()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue