summaryrefslogtreecommitdiffstats
path: root/bsps/sparc/leon3/config/gr740.cfg
diff options
context:
space:
mode:
Diffstat (limited to 'bsps/sparc/leon3/config/gr740.cfg')
-rw-r--r--bsps/sparc/leon3/config/gr740.cfg23
1 files changed, 22 insertions, 1 deletions
diff --git a/bsps/sparc/leon3/config/gr740.cfg b/bsps/sparc/leon3/config/gr740.cfg
index 86da029c42..640a4fdd72 100644
--- a/bsps/sparc/leon3/config/gr740.cfg
+++ b/bsps/sparc/leon3/config/gr740.cfg
@@ -1 +1,22 @@
-include $(RTEMS_ROOT)/make/custom/leon3.cfg
+#
+# Config file for the LEON3 SPARC processor.
+#
+
+include $(RTEMS_ROOT)/make/custom/default.cfg
+
+RTEMS_CPU=sparc
+
+# This contains the compiler options necessary to select the CPU model
+# and (hopefully) optimize for it.
+# GCC and clang use different switches to select target:
+ifneq (,$(findstring clang,$(CC)))
+ CPU_CFLAGS = -mcpu=gr740
+else
+ CPU_CFLAGS = -mcpu=leon3
+endif
+
+# optimize flag: typically -O2
+CFLAGS_OPTIMIZE_V = -O2 -g
+CFLAGS_OPTIMIZE_V += -ffunction-sections -fdata-sections
+
+LDFLAGS = -Wl,--gc-sections