From f3b4b17bdf4c4e56f70c6899d688319d475cd141 Mon Sep 17 00:00:00 2001 From: Daniele Lacamera Date: Thu, 7 Aug 2025 19:38:10 +0200 Subject: [PATCH 1/2] Fixed build with Cmake on STM32H7 with TEST_APPS. As reported in #586 --- ...e code, I notice that in the STM32H7 section, there's a line | 0 test-app/CMakeLists.txt | 2 +- test-app/startup_arm.c | 2 ++ 3 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 Looking at the code, I notice that in the STM32H7 section, there's a line diff --git a/Looking at the code, I notice that in the STM32H7 section, there's a line b/Looking at the code, I notice that in the STM32H7 section, there's a line new file mode 100644 index 0000000000..e69de29bb2 diff --git a/test-app/CMakeLists.txt b/test-app/CMakeLists.txt index 831573fd2c..b1cde98791 100644 --- a/test-app/CMakeLists.txt +++ b/test-app/CMakeLists.txt @@ -126,7 +126,7 @@ if(BUILD_TEST_APPS) if(WOLFBOOT_TARGET STREQUAL "sim") target_link_options(image PRIVATE -Wl,-gc-sections -Wl,-Map=image.map) else() - target_link_options(image PRIVATE -T${APP_LSCRIPT} -Wl,-gc-sections -Wl,-Map=image.map) + target_link_options(image PRIVATE -T${APP_LSCRIPT} -Wl,-gc-sections -Wl,-Map=image.map -ffreestanding -nostartfiles) endif() if(WOLFBOOT_TARGET IN_LIST ARM_TARGETS) diff --git a/test-app/startup_arm.c b/test-app/startup_arm.c index 68d41adf69..4cb5466c93 100644 --- a/test-app/startup_arm.c +++ b/test-app/startup_arm.c @@ -31,6 +31,8 @@ extern unsigned int _start_heap; #ifdef TARGET_stm32f4 extern void isr_tim2(void); +#else +#define isr_tim2 isr_empty #endif #ifdef TARGET_stm32h5 From 273c6187ddd104ebe9d6508693517d2df19447fa Mon Sep 17 00:00:00 2001 From: Daniele Lacamera Date: Thu, 14 Aug 2025 22:06:13 +0200 Subject: [PATCH 2/2] Removed weird file accidentally committed --- ...the code, I notice that in the STM32H7 section, there's a line | 0 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 Looking at the code, I notice that in the STM32H7 section, there's a line diff --git a/Looking at the code, I notice that in the STM32H7 section, there's a line b/Looking at the code, I notice that in the STM32H7 section, there's a line deleted file mode 100644 index e69de29bb2..0000000000