On Fri, 1 Nov 2019 at 21:55, Hauke Mehrtens <[email protected]> wrote: > > This decreases the binary size when PIE ASLR is activated by 8% on MIPS BE. > > old: > 202,020 /usr/sbin/dnsmasq > > new: > 185,676 /usr/sbin/dnsmasq
Nice reduction. > > Signed-off-by: Hauke Mehrtens <[email protected]> > --- > package/network/services/dnsmasq/Makefile | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/package/network/services/dnsmasq/Makefile > b/package/network/services/dnsmasq/Makefile > index 5c114eb1c6..e86b031e3f 100644 > --- a/package/network/services/dnsmasq/Makefile > +++ b/package/network/services/dnsmasq/Makefile > @@ -127,8 +127,8 @@ endef > Package/dnsmasq-dhcpv6/conffiles = $(Package/dnsmasq/conffiles) > Package/dnsmasq-full/conffiles = $(Package/dnsmasq/conffiles) > > -TARGET_CFLAGS += -ffunction-sections -fdata-sections > -TARGET_LDFLAGS += -Wl,--gc-sections > +TARGET_CFLAGS += -flto > +TARGET_LDFLAGS += -flto=jobserver Maybe add a PKG_LTO (or so) flag packages can set, and add these flags then automatically? Less code churn per package. Regards Jonas _______________________________________________ openwrt-devel mailing list [email protected] https://lists.openwrt.org/mailman/listinfo/openwrt-devel
