1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

wscript: use --as-needed only if tested successfully

Some OSes like Solaris based OmiOS don't support this.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14288

Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Björn Jacke 2021-03-02 22:47:35 +01:00 committed by Bjoern Jacke
parent 1c9add5475
commit 996560191a

View File

@ -340,7 +340,8 @@ def configure(conf):
# allows us to find problems on our development hosts faster.
# It also results in faster load time.
conf.add_as_needed()
conf.ADD_LDFLAGS('-Wl,--as-needed', testflags=True)
if not conf.CHECK_NEED_LC("-lc not needed"):
conf.ADD_LDFLAGS('-lc', testflags=False)