diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2014-05-28 17:56:26 +0200 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2014-05-28 17:56:42 +0200 |
commit | f09c62954e2f585026ca0f09d199eee3644a5c1a (patch) | |
tree | 92e2414f066bc99ff8de11aae6e818bd316553de /mk | |
parent | 9fd20ed0d2e2ec895f4b6987ab610968bd9a93e3 (diff) |
allow to choose ld garbage collector
Diffstat (limited to 'mk')
-rw-r--r-- | mk/vars.mk | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/mk/vars.mk b/mk/vars.mk index ef87acb79..7179eb145 100644 --- a/mk/vars.mk +++ b/mk/vars.mk @@ -124,6 +124,12 @@ TARGET_CFLAGS+= -fPIE TARGET_CXXFLAGS+= -fPIE endif +ifneq ($(ADK_TARGET_USE_LD_GC),) +TARGET_CFLAGS+= -fdata-sections -ffunction-sections +TARGET_CXXFLAGS+= -fdata-sections -ffunction-sections +TARGET_LDFLAGS+= -Wl,--gc-sections +endif + ifneq ($(ADK_TARGET_USE_LTO),) TARGET_CFLAGS+= -flto TARGET_CXXFLAGS+= -flto |