mirror of
https://github.com/apache/nuttx.git
synced 2026-05-26 10:46:28 +08:00
cmake(feat):implements KERNEL mode in CMake build
1.add application link dependencies for all elf
2.add a global custom target to hold proptry in the toolchain file
3.add startup obj target
4.fix cpp lds error with kernel mod link elf lds
usage:
./build.sh qemu-armv7a:knsh --cmake
elf install in ${CMAKE_BINARY_DIR}/bin
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
This commit is contained in:
@@ -49,4 +49,13 @@ if(CONFIG_LIBC_ELF)
|
||||
|
||||
target_sources(c PRIVATE ${SRCS})
|
||||
|
||||
set(ELF_LD_SCRIPT_TMP "${CMAKE_BINARY_DIR}/gnu-elf.ld")
|
||||
|
||||
nuttx_generate_preprocess_target(
|
||||
SOURCE_FILE ${NUTTX_DIR}/libs/libc/elf/gnu-elf.ld.in TARGET_FILE
|
||||
${ELF_LD_SCRIPT_TMP})
|
||||
|
||||
add_custom_target(elfldscript_tmp DEPENDS ${ELF_LD_SCRIPT_TMP})
|
||||
add_dependencies(nuttx elfldscript_tmp)
|
||||
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user