summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZixun LI <[email protected]>2025-12-16 12:40:44 +0100
committerZixun LI <[email protected]>2025-12-16 12:40:44 +0100
commitcb1873881e3cc51f522978e165748ad7ef7a7b0a (patch)
tree7fec1c1311661fe50cd9dc4b3f9f545df7439611
parentc130fc07c628a0b2d79f35b743857aa53d79130b (diff)
fix build
Signed-off-by: Zixun LI <[email protected]>
-rw-r--r--hw/bsp/rw61x/family.cmake14
1 files changed, 11 insertions, 3 deletions
diff --git a/hw/bsp/rw61x/family.cmake b/hw/bsp/rw61x/family.cmake
index 62233a404..8c332f96e 100644
--- a/hw/bsp/rw61x/family.cmake
+++ b/hw/bsp/rw61x/family.cmake
@@ -81,10 +81,18 @@ function(family_configure_example TARGET RTOS)
if (CMAKE_C_COMPILER_ID STREQUAL "GNU")
target_link_options(${TARGET} PUBLIC
"LINKER:--script=${LD_FILE_GNU}"
- --specs=nosys.specs
- --specs=nano.specs
+ --specs=nosys.specs --specs=nano.specs
+ -nostartfiles
)
- endif()
+ elseif (CMAKE_C_COMPILER_ID STREQUAL "Clang")
+ target_link_options(${TARGET} PUBLIC
+ "LINKER:--script=${LD_FILE_Clang}"
+ )
+ elseif (CMAKE_C_COMPILER_ID STREQUAL "IAR")
+ target_link_options(${TARGET} PUBLIC
+ "LINKER:--config=${LD_FILE_IAR}"
+ )
+ endif ()
if (CMAKE_C_COMPILER_ID STREQUAL "GNU" OR CMAKE_C_COMPILER_ID STREQUAL "Clang")
set_source_files_properties(${CMAKE_CURRENT_FUNCTION_LIST_DIR}/family.c PROPERTIES COMPILE_FLAGS "-Wno-missing-prototypes")