diff options
author | Stefan Metzmacher <metze@sernet.private> | 2010-03-04 11:14:51 +0100 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2010-03-04 13:02:16 +0100 |
commit | 22d316926b9589608d332143c1fa134229b75b3c (patch) | |
tree | d704fbc6f075581c720699f2df43d9083af4297b /source3 | |
parent | af6f59468ab157d125e14a649ee1d55bd17e8d1a (diff) | |
download | samba-22d316926b9589608d332143c1fa134229b75b3c.tar.gz samba-22d316926b9589608d332143c1fa134229b75b3c.tar.bz2 samba-22d316926b9589608d332143c1fa134229b75b3c.zip |
s3:configure: add --enable-as-needed
On some broken systems like RHEL5, we need to be able
to disable --as-needed.
metze
Diffstat (limited to 'source3')
-rw-r--r-- | source3/configure.in | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/source3/configure.in b/source3/configure.in index 7ba72bf26c..5283d8f99a 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -1746,7 +1746,12 @@ fi AC_MSG_RESULT($BLDSHARED) -for flags in "-Wl,--as-needed" "-Wl,-z,ignore" "-z ignore" ; do +AC_ARG_ENABLE(as-needed, + [AS_HELP_STRING([--enable-as-needed], + [Turn on as-needed support if available (default=yes)])]) + +if test "x$enable_as_needed" != xno; then + for flags in "-Wl,--as-needed" "-Wl,-z,ignore" "-z ignore" ; do saved_ldflags="$LDFLAGS" AC_MSG_CHECKING([if $flags works]) LDFLAGS="$flags $saved_ldflags" @@ -1757,7 +1762,8 @@ for flags in "-Wl,--as-needed" "-Wl,-z,ignore" "-z ignore" ; do AC_MSG_RESULT([no])) LDFLAGS="$LD_AS_NEEDED_FLAG $saved_ldflags" test x"$ld_as_needed_flag_found" = xyes && break -done + done +fi # for historical reasons almost all linkers don't complain about unresolved # symbols in shared libs. Except for the internal samba modules we want to get |