From: Felix Fietkau Date: Wed, 11 Jul 2018 16:55:02 +0000 (+0200) Subject: netifd: compile with LTO enabled X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=07940acc341ee9bb2887359f193625e48f36207e;p=openwrt%2Fstaging%2Fyousong.git netifd: compile with LTO enabled Reduces .ipk size from 65k to 63k on MIPS Signed-off-by: Felix Fietkau --- diff --git a/package/network/config/netifd/Makefile b/package/network/config/netifd/Makefile index c18496c923..2eaf38d580 100644 --- a/package/network/config/netifd/Makefile +++ b/package/network/config/netifd/Makefile @@ -27,7 +27,10 @@ endef TARGET_CFLAGS += \ -I$(STAGING_DIR)/usr/include/libnl-tiny \ - -I$(STAGING_DIR)/usr/include + -I$(STAGING_DIR)/usr/include \ + -flto + +TARGET_LDFLAGS += -flto -fuse-linker-plugin CMAKE_OPTIONS += \ -DLIBNL_LIBS=-lnl-tiny \