1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00

r19091: merge from samba3:

remove some -Wl,-rpath combinations with /usr/lib

metze
(This used to be commit 66c6aab37e)
This commit is contained in:
Stefan Metzmacher 2006-10-05 07:47:56 +00:00 committed by Gerald (Jerry) Carter
parent a484b8367b
commit df31092a01

27
source4/aclocal.m4 vendored
View File

@ -22,13 +22,32 @@ AC_DEFUN(CFLAGS_REMOVE_USR_INCLUDE,[
$1=[$]ac_new_flags $1=[$]ac_new_flags
]) ])
dnl Removes -L/usr/lib/? from given variable dnl Removes '-L/usr/lib[/]', '-Wl,-rpath,/usr/lib[/]'
dnl and '-Wl,-rpath -Wl,/usr/lib[/]' from given variable
AC_DEFUN(LIB_REMOVE_USR_LIB,[ AC_DEFUN(LIB_REMOVE_USR_LIB,[
ac_new_flags="" ac_new_flags=""
l=""
for i in [$]$1; do for i in [$]$1; do
case [$]i in case [$]l[$]i in
-L/usr/lib|-L/usr/lib/) ;; -L/usr/lib) ;;
*) ac_new_flags="[$]ac_new_flags [$]i" ;; -L/usr/lib/) ;;
-Wl,-rpath,/usr/lib) ;;
-Wl,-rpath,/usr/lib/) ;;
-Wl,-rpath) l=[$]i;;
-Wl,-rpath-Wl,/usr/lib) l="";;
-Wl,-rpath-Wl,/usr/lib/) l="";;
*)
s=" "
if test x"[$]ac_new_flags" = x""; then
s="";
fi
if test x"[$]l" = x""; then
ac_new_flags="[$]ac_new_flags[$]s[$]i";
else
ac_new_flags="[$]ac_new_flags[$]s[$]l [$]i";
fi
l=""
;;
esac esac
done done
$1=[$]ac_new_flags $1=[$]ac_new_flags