2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-09-05 08:45:28 +00:00

Use AX_APPEND_FLAG instead of SUDO_APPEND_CPPFLAGS and direct

modification of LDFLAGS.
This commit is contained in:
Todd C. Miller
2016-11-17 10:16:51 -07:00
parent a77ecca7d3
commit cb7e82acca
6 changed files with 1730 additions and 363 deletions

View File

@@ -346,33 +346,10 @@ dnl Append a libpath to an LDFLAGS style variable if not already present.
dnl Also appends to the _R version unless rpath is disabled.
dnl
AC_DEFUN([SUDO_APPEND_LIBPATH], [
case "${$1}" in
*"-L$2"|*"-L$2 ")
;;
*)
$1="${$1} -L$2"
if test X"$enable_rpath" = X"yes"; then
$1_R="${$1_R} -R$2"
fi
;;
esac
])
dnl
dnl Append a directory to CPPFLAGS if not already present.
dnl
AC_DEFUN([SUDO_APPEND_CPPFLAGS], [
case "${CPPFLAGS}" in
*"$1"|*"$1 ")
;;
*)
if test X"${CPPFLAGS}" = X""; then
CPPFLAGS="$1"
else
CPPFLAGS="${CPPFLAGS} $1"
fi
;;
esac
AX_APPEND_FLAG([-L$2], [$1])
if test X"$enable_rpath" = X"yes"; then
AX_APPEND_FLAG([-R$2], [$1_R])
fi
])
dnl