build-sys: prevent library underlinking

Underlinking can cause subtle bugs like the recent issue with
libnss_myhostname (which was fixed in commit 1e335af7).
This commit is contained in:
Evangelos Foutras
2013-04-19 18:15:45 -04:00
committed by Zbigniew Jędrzejewski-Szmek
parent 1e335af70f
commit 9d2d0fe1e3
+1
View File
@@ -144,6 +144,7 @@ AC_SUBST([OUR_CPPFLAGS], $with_cppflags)
CC_CHECK_FLAGS_APPEND([with_ldflags], [LDFLAGS], [\
-Wl,--as-needed \
-Wl,--no-undefined \
-Wl,--gc-sections \
-Wl,-z,relro \
-Wl,-z,now])