From 553029b88b470362b533bbd17d028e6e61e4b8b9 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 3 Nov 2010 10:50:16 +1100 Subject: s4-build: use -Wl,--as-needed if supported this makes our runtime load times smaller, and also means we find bugs that this may cause on gentoo. gentoo uses this by default Autobuild-User: Andrew Tridgell Autobuild-Date: Wed Nov 3 00:35:56 UTC 2010 on sn-devel-104 --- source4/wscript | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/source4/wscript b/source4/wscript index cbc0bf49ac..ac4971ca6a 100644 --- a/source4/wscript +++ b/source4/wscript @@ -118,6 +118,12 @@ def configure(conf): # resolution of symbols conf.ADD_LDFLAGS('-Wl,-no-undefined', testflags=True) + # gentoo always adds this. We want our normal build to be as + # strict as the strictest OS we support, so adding this here + # allows us to find problems on our development hosts faster. + # It also results in faster load time. + conf.ADD_LDFLAGS('-Wl,--as-needed', testflags=True) + # we don't want PYTHONDIR in config.h, as otherwise changing # --prefix causes a complete rebuild del(conf.env.defines['PYTHONDIR']) -- cgit