diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2019-10-27 22:32:59 +0100 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2019-11-30 00:18:40 +0100 |
commit | 5cb845ebfedb57716d8694026b9d3f3a2638d2bf (patch) | |
tree | d5502c21baf3d10fe5a432f27bcf536a0503d00e /package/system/mtd | |
parent | c38074de929e6f7c089e2cb7f81746ba90ddf16b (diff) | |
download | upstream-5cb845ebfedb57716d8694026b9d3f3a2638d2bf.tar.gz upstream-5cb845ebfedb57716d8694026b9d3f3a2638d2bf.tar.bz2 upstream-5cb845ebfedb57716d8694026b9d3f3a2638d2bf.zip |
mtd: Activate LTO compile option
This decreases the size of the mtd application by 25% on MIPS BE.
old:
20,597 /sbin/mtd
new:
16,421 /sbin/mtd
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
(cherry picked from commit 1eb34b7287ed97ad1e2ae60a436babbb5c68076f)
Diffstat (limited to 'package/system/mtd')
-rw-r--r-- | package/system/mtd/Makefile | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/package/system/mtd/Makefile b/package/system/mtd/Makefile index c307555436..17df3bc475 100644 --- a/package/system/mtd/Makefile +++ b/package/system/mtd/Makefile @@ -36,7 +36,8 @@ endef target=$(firstword $(subst -, ,$(BOARD))) MAKE_FLAGS += TARGET="$(target)" -TARGET_CFLAGS := $(TARGET_CFLAGS) -Dtarget_$(target)=1 -Wall +TARGET_CFLAGS += -Dtarget_$(target)=1 -Wall -flto +TARGET_LDFLAGS += -flto=jobserver ifdef CONFIG_MTD_REDBOOT_PARTS MAKE_FLAGS += FIS_SUPPORT=1 |