summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAun-Ali Zaidi <admin@kodeit.net>2016-01-07 22:16:03 -0600
committerJoel Sherrill <joel.sherrill@oarcorp.com>2016-01-09 09:34:27 -0600
commitc7d29abe16992978ef14294027ee8f6d7c8c7d45 (patch)
tree88541753da72d528a99d22a744fe52b8442786e0
parent89ecb7f4342a219cd4baf0bd374dd20557dfaf00 (diff)
downloadrtems-c7d29abe16992978ef14294027ee8f6d7c8c7d45.tar.bz2
arm/csb336: Add per-section compilation and linking support
The size of the sample executables without this option were: text data bss dec hex filename 107316 1948 31315236 31424500 1df7ff4 minimum.exe 124196 2076 31298244 31424516 1df8004 base_sp.exe 144584 2164 31277760 31424508 1df7ffc nsecs.exe 193600 2560 31228356 31424516 1df8004 capture.exe 222500 2104 31199904 31424508 1df7ffc cdtest.exe 189728 2460 31232324 31424512 1df8000 paranoia.exe 114336 2028 31308132 31424496 1df7ff0 hello.exe 565800 5988 30852708 31424496 1df7ff0 fileio.exe 127620 2076 31294820 31424516 1df8004 ticker.exe 274060 6864 31143584 31424508 1df7ffc loopback.exe 612008 2296 30810208 31424512 1df8000 cxx_iostream.exe 452432 12972 30959104 31424508 1df7ffc pppd.exe 127020 2084 31295396 31424500 1df7ff4 unlimited.exe The size of the sample executables with this option enabled were: text data bss dec hex filename 32008 1436 31391076 31424520 1df8008 minimum.exe 119172 1924 31303396 31424492 1df7fec base_sp.exe 139648 2012 31282848 31424508 1df7ffc nsecs.exe 185688 2400 31236420 31424508 1df7ffc capture.exe 214612 1952 31207936 31424500 1df7ff4 cdtest.exe 184040 2308 31238148 31424496 1df7ff0 paranoia.exe 108352 1868 31314276 31424496 1df7ff0 hello.exe 549616 5836 30869060 31424512 1df8000 fileio.exe 122580 1924 31300004 31424508 1df7ffc ticker.exe 254020 6616 31163872 31424508 1df7ffc loopback.exe 435508 2136 30986852 31424496 1df7ff0 cxx_iostream.exe 419288 12688 30992516 31424492 1df7fec pppd.exe 121396 1924 31301188 31424508 1df7ffc unlimited.exe
-rw-r--r--c/src/lib/libbsp/arm/csb336/make/custom/csb336.cfg4
1 files changed, 4 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/arm/csb336/make/custom/csb336.cfg b/c/src/lib/libbsp/arm/csb336/make/custom/csb336.cfg
index 369377040d..535b66610d 100644
--- a/c/src/lib/libbsp/arm/csb336/make/custom/csb336.cfg
+++ b/c/src/lib/libbsp/arm/csb336/make/custom/csb336.cfg
@@ -13,3 +13,7 @@ CPU_CFLAGS = -mcpu=arm920
# optimize flag: typically -O2
CFLAGS_OPTIMIZE_V = -O2 -g
+
+# Add CFLAGS and LDFLAGS for compiling and linking with per item sections
+CFLAGS_OPTIMIZE_V += -ffunction-sections -fdata-sections
+LDFLAGS = -Wl,--gc-sections