From: Michael Stapelberg Date: Mon, 1 Aug 2011 14:13:38 +0000 (+0200) Subject: LDFLAGS: add -Wl,--as-needed. reduces .so dependencies X-Git-Tag: 4.0.1~5 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=3c68a9158c28625e5fd04781e4f14c598a56b720;p=i3%2Fi3 LDFLAGS: add -Wl,--as-needed. reduces .so dependencies Let’s see if that works on all systems :) --- diff --git a/common.mk b/common.mk index d7c0c5ac..05b10611 100644 --- a/common.mk +++ b/common.mk @@ -71,6 +71,8 @@ LIBS += $(call ldflags_for_lib, x11, X11) LIBS += $(call ldflags_for_lib, yajl, yajl) LIBS += $(call ldflags_for_lib, libev, ev) +LDFLAGS += -Wl,--as-needed + ifeq ($(UNAME),NetBSD) # We need -idirafter instead of -I to prefer the system’s iconv over GNU libiconv CFLAGS += -idirafter /usr/pkg/include