]> granicus.if.org Git - sudo/commitdiff
Don't add -llber twice.
authorTodd C. Miller <Todd.Miller@courtesan.com>
Tue, 15 Jan 2008 12:28:33 +0000 (12:28 +0000)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Tue, 15 Jan 2008 12:28:33 +0000 (12:28 +0000)
configure
configure.in

index 425b62a1bbb2689fc73b742271b3cb75547f77a5..c56e0bdef23c37c03193903a310f417430ee0d37 100755 (executable)
--- a/configure
+++ b/configure
@@ -21899,7 +21899,8 @@ echo "${ECHO_T}not found, using -lldap" >&6; }
        { echo "$as_me:$LINENO: result: $LDAP_LIBS" >&5
 echo "${ECHO_T}$LDAP_LIBS" >&6; }
     fi
-        { echo "$as_me:$LINENO: checking for library containing ber_set_option" >&5
+        OLIBS="$LIBS"
+    { echo "$as_me:$LINENO: checking for library containing ber_set_option" >&5
 echo $ECHO_N "checking for library containing ber_set_option... $ECHO_C" >&6; }
 if test "${ac_cv_search_ber_set_option+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -21984,10 +21985,8 @@ else
   found=no
 fi
 
-    if test $found="yes"; then
-       case "$LIBS" in
-           *-llber*)   LDAP_LIBS="$LDAP_LIBS -llber";;
-       esac
+    if test X"$found" = X"yes" -a X"$LIBS" != X"$OLIBS"; then
+       LDAP_LIBS="$LDAP_LIBS -llber"
     fi
         { echo "$as_me:$LINENO: checking whether lber.h is needed" >&5
 echo $ECHO_N "checking whether lber.h is needed... $ECHO_C" >&6; }
index 8762e13de93703b808cb32d72ae22849731e2cf8..60349e805c0f3cdd8762caa7f3d8ccb1b458bd08 100644 (file)
@@ -2299,12 +2299,11 @@ if test ${with_ldap-'no'} != "no"; then
     else
        AC_MSG_RESULT([$LDAP_LIBS])
     fi
-    dnl check if we need to link with -llbre for ber_set_option
+    dnl check if we need to link with -llber for ber_set_option
+    OLIBS="$LIBS"
     AC_SEARCH_LIBS([ber_set_option], [lber], [found=yes], [found=no])
-    if test $found="yes"; then
-       case "$LIBS" in
-           *-llber*)   LDAP_LIBS="$LDAP_LIBS -llber";;
-       esac
+    if test X"$found" = X"yes" -a X"$LIBS" != X"$OLIBS"; then
+       LDAP_LIBS="$LDAP_LIBS -llber"
     fi
     dnl check if ldap.h includes lber.h for us
     AC_MSG_CHECKING([whether lber.h is needed])