From b14dd86728954769d61e3a97e3303d0e55d8b8b8 Mon Sep 17 00:00:00 2001 From: Silvano Seva Date: Wed, 31 May 2023 22:24:33 +0200 Subject: [PATCH] Added -fdata-sections directive to compiler and linker arguments for ARM targets --- cross_arm.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cross_arm.txt b/cross_arm.txt index 0f261e43..ebaf0f38 100644 --- a/cross_arm.txt +++ b/cross_arm.txt @@ -16,6 +16,7 @@ openocd = '/usr/local/bin/openocd' c_args = [ '-D_DEFAULT_SOURCE=1', '-ffunction-sections', + '-fdata-sections', '-Wall', '-Werror=return-type', '-g', @@ -29,6 +30,7 @@ c_args = [ cpp_args = [ '-D_DEFAULT_SOURCE=1', '-ffunction-sections', + '-fdata-sections', '-Wall', '-Werror=return-type', '-g', @@ -48,6 +50,8 @@ c_link_args = [ '-mthumb', '-mfloat-abi=hard', '-mfpu=fpv4-sp-d16', + '-ffunction-sections', + '-fdata-sections', '-fno-exceptions', '-fno-rtti', '-Wl,-L../lib/miosix-kernel',