summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.inc3
1 files changed, 3 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.inc b/c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.inc
index 3b4fb50e58..a8b6f264c3 100644
--- a/c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.inc
+++ b/c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.inc
@@ -7,6 +7,9 @@ include $(RTEMS_ROOT)/make/custom/default.cfg
RTEMS_CPU = arm
CFLAGS_OPTIMIZE_V ?= -O2 -g
+CFLAGS_OPTIMIZE_V += -ffunction-sections -fdata-sections
+
+LDFLAGS = -Wl,--gc-sections
# This defines the operations performed on the linked executable.
# is currently required.