]> granicus.if.org Git - sudo/commitdiff
regen
authorTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 21 Mar 2003 19:02:05 +0000 (19:02 +0000)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 21 Mar 2003 19:02:05 +0000 (19:02 +0000)
configure

index c4a41765a4ede72c01e06842b6c438f6df4f7b8f..d570f131149b1e4e3a935a7191c93b01b3905d1b 100755 (executable)
--- a/configure
+++ b/configure
@@ -865,6 +865,8 @@ Optional Packages:
   --with-otp-only         deprecated
   --with-alertmail        deprecated
   --with-CC               C compiler to use
+  --with-rpath            pass -R flag in addition to -L for lib paths
+  --with-blibpath=PATH  pass -blibpath flag to ld for additional lib paths
   --with-incpath          additional places to look for include files
   --with-libpath          additional places to look for libraries
   --with-libraries        additional libraries to link with
@@ -872,8 +874,8 @@ Optional Packages:
   --with-efence           link with -lefence for malloc() debugging
   --with-csops            add CSOps standard options
   --without-passwd        don't use passwd/shadow file for authentication
-  --with-skey             enable S/Key support
-  --with-opie             enable OPIE support
+  --with-skey=DIR       enable S/Key support
+  --with-opie=DIR       enable OPIE support
   --with-long-otp-prompt  use a two line OTP (skey/opie) prompt
   --with-SecurID[=DIR]    enable SecurID support
   --with-fwtk[=DIR]       enable FWTK AuthSRV support
@@ -1473,6 +1475,33 @@ esac
 fi;
 
 
+# Check whether --with-rpath or --without-rpath was given.
+if test "${with_rpath+set}" = set; then
+  withval="$with_rpath"
+  case $with_rpath in
+    yes)       ;;
+    no)                ;;
+    *)         { { echo "$as_me:$LINENO: error: \"--with-rpath does not take an argument.\"" >&5
+echo "$as_me: error: \"--with-rpath does not take an argument.\"" >&2;}
+   { (exit 1); exit 1; }; }
+               ;;
+esac
+fi;
+
+
+# Check whether --with-blibpath or --without-blibpath was given.
+if test "${with_blibpath+set}" = set; then
+  withval="$with_blibpath"
+  case $with_blibpath in
+    yes)       ;;
+    no)                ;;
+    *)         { echo "$as_me:$LINENO: will pass -blibpath:${with_blibpath} to the loader." >&5
+echo "$as_me: will pass -blibpath:${with_blibpath} to the loader." >&6;}
+               ;;
+esac
+fi;
+
+
 # Check whether --with-incpath or --without-incpath was given.
 if test "${with_incpath+set}" = set; then
   withval="$with_incpath"
@@ -1509,9 +1538,6 @@ echo "$as_me: error: \"--without-libpath not supported.\"" >&2;}
                ;;
     *)         { echo "$as_me:$LINENO: Adding ${with_libpath} to LDFLAGS" >&5
 echo "$as_me: Adding ${with_libpath} to LDFLAGS" >&6;}
-               for i in ${with_libpath}; do
-                   LDFLAGS="${LDFLAGS} -L${i}"
-               done
                ;;
 esac
 fi;
@@ -1531,15 +1557,6 @@ echo "$as_me: error: \"--without-libraries not supported.\"" >&2;}
                ;;
     *)         { echo "$as_me:$LINENO: Adding ${with_libraries} to LIBS" >&5
 echo "$as_me: Adding ${with_libraries} to LIBS" >&6;}
-               for i in ${with_libraries}; do
-                   case $i in
-                       -l*)    ;;
-                       *.a)    ;;
-                       *.o)    ;;
-                       *)      i="-l${i}";;
-                   esac
-                   LIBS="${LIBS} ${i}"
-               done
                ;;
 esac
 fi;
@@ -1571,7 +1588,7 @@ if test "${with_efence+set}" = set; then
 echo "$as_me: Sudo will link with -lefence (Electric Fence)" >&6;}
                LIBS="${LIBS} -lefence"
                if test -f /usr/local/lib/libefence.a; then
-                   LDFLAGS="${LDFLAGS} -L/usr/local/lib"
+                   with_libpath="${with_libpath} /usr/local/lib"
                fi
                ;;
     no)                ;;
@@ -1629,7 +1646,8 @@ fi;
 if test "${with_skey+set}" = set; then
   withval="$with_skey"
   case $with_skey in
-    yes)       if test -n "$with_opie"; then
+    no)                with_skey="";;
+    *)         if test -n "$with_opie"; then
                    { { echo "$as_me:$LINENO: error: \"cannot use both S/Key and OPIE\"" >&5
 echo "$as_me: error: \"cannot use both S/Key and OPIE\"" >&2;}
    { (exit 1); exit 1; }; }
@@ -1645,10 +1663,6 @@ echo $ECHO_N "checking whether to try S/Key authentication... $ECHO_C" >&6
 echo "${ECHO_T}yes" >&6
                AUTH_OBJS="${AUTH_OBJS} rfc1938.o"
                ;;
-    no)                ;;
-    *)         { echo "$as_me:$LINENO: WARNING: Ignoring unknown argument to --with-skey: $with_skey" >&5
-echo "$as_me: WARNING: Ignoring unknown argument to --with-skey: $with_skey" >&2;}
-               ;;
 esac
 fi;
 
@@ -1657,7 +1671,8 @@ fi;
 if test "${with_opie+set}" = set; then
   withval="$with_opie"
   case $with_opie in
-    yes)       if test -n "$with_skey"; then
+    no)                with_opie="";;
+    *)         if test -n "$with_skey"; then
                    { { echo "$as_me:$LINENO: error: \"cannot use both S/Key and OPIE\"" >&5
 echo "$as_me: error: \"cannot use both S/Key and OPIE\"" >&2;}
    { (exit 1); exit 1; }; }
@@ -1673,10 +1688,6 @@ echo $ECHO_N "checking whether to try NRL OPIE authentication... $ECHO_C" >&6
 echo "${ECHO_T}yes" >&6
                AUTH_OBJS="${AUTH_OBJS} rfc1938.o"
                ;;
-    no)                ;;
-    *)         { echo "$as_me:$LINENO: WARNING: Ignoring unknown argument to --with-opie: $with_opie" >&5
-echo "$as_me: WARNING: Ignoring unknown argument to --with-opie: $with_opie" >&2;}
-               ;;
 esac
 fi;
 
@@ -1742,11 +1753,6 @@ echo $ECHO_N "checking whether to use FWTK AuthSRV for authentication... $ECHO_C
 echo "${ECHO_T}yes" >&6
                with_passwd=no
                AUTH_OBJS="fwtk.o"
-               if test "$with_fwtk" != "yes"; then
-                   SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_fwtk}"
-                   CPPFLAGS="${CPPFLAGS} -I${with_fwtk}"
-                   with_fwtk=yes
-               fi
                ;;
 esac
 fi;
@@ -4905,6 +4911,7 @@ done
                fi
                test -n "$mansectsu" || mansectsu=1m
                test -n "$mansectform" || mansectform=4
+               test -n "$with_rpath" || with_rpath=yes
                ;;
     *-*-aix*)
                # To get all prototypes (so we pass -Wall)
@@ -4914,6 +4921,60 @@ done
 EOF
 
                SUDO_LDFLAGS="${SUDO_LDFLAGS} -Wl,-bI:\$(srcdir)/aixcrypt.exp"
+               if test X"$with_blibpath" != X"no"; then
+                   echo "$as_me:$LINENO: checking if linker accepts -Wl,-blibpath" >&5
+echo $ECHO_N "checking if linker accepts -Wl,-blibpath... $ECHO_C" >&6
+                   O_LDFLAGS="$LDFLAGS"
+                   LDFLAGS="$LDFLAGS -Wl,-blibpath:/usr/lib:/lib"
+                   cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+
+                       if test -n "$with_blibpath" -a "$with_blibpath" != "yes"; then
+                           blibpath="$with_blibpath"
+                       elif test -n "$GCC"; then
+                           blibpath="/usr/lib:/lib:/usr/local/lib"
+                       else
+                           blibpath="/usr/lib:/lib"
+                       fi
+                       echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+               fi
+               LDFLAGS="$O_LDFLAGS"
                ;;
     *-*-hiuxmpp*)
                if test "$CHECKSHADOW" = "true"; then
@@ -6528,6 +6589,7 @@ fi
                fi
                test -n "$mansectsu" || mansectsu=1m
                test -n "$mansectform" || mansectform=4
+               test -n "$with_rpath" || with_rpath=yes
                ;;
     *-ncr-sysv4*|*-ncr-sysvr4*)
                echo "$as_me:$LINENO: checking for strcasecmp in -lc89" >&5
@@ -6593,12 +6655,14 @@ fi
 
                test -n "$mansectsu" || mansectsu=1m
                test -n "$mansectform" || mansectform=4
+               test -n "$with_rpath" || with_rpath=yes
                ;;
     *-ccur-sysv4*|*-ccur-sysvr4*)
                LIBS="${LIBS} -lgen"
                SUDO_LIBS="${SUDO_LIBS} -lgen"
                test -n "$mansectsu" || mansectsu=1m
                test -n "$mansectform" || mansectform=4
+               test -n "$with_rpath" || with_rpath=yes
                ;;
     *-*-bsdi*)
                SKIP_SETREUID=yes
@@ -6658,6 +6722,11 @@ echo "$as_me: using shlicc as CC" >&6;}
                ac_cv_func_lockf=no
                ac_cv_func_flock=yes
                ;;
+    *-*-*sysv4*)
+               test -n "$mansectsu" || mansectsu=1m
+               test -n "$mansectform" || mansectform=4
+               test -n "$with_rpath" || with_rpath=yes
+               ;;
     *-*-sysv*)
                test -n "$mansectsu" || mansectsu=1m
                test -n "$mansectform" || mansectform=4
@@ -6667,6 +6736,32 @@ esac
 test -n "$mansectsu" || mansectsu=8
 test -n "$mansectform" || mansectform=5
 
+if test -n "$with_libpath"; then
+    for i in ${with_libpath}; do
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L$i -R$i"
+    else
+       LDFLAGS="${LDFLAGS} -L$i"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:$i"
+    fi
+
+    done
+fi
+if test -n "$with_libraries"; then
+    for i in ${with_libraries}; do
+       case $i in
+           -l*)        ;;
+           *.a)        ;;
+           *.o)        ;;
+           *)  i="-l${i}";;
+       esac
+       LIBS="${LIBS} ${i}"
+    done
+fi
+
 if test "$CHECKSHADOW" = "true"; then
 
 for ac_func in getspnam
@@ -12397,7 +12492,8 @@ cat >>confdefs.h <<\_ACEOF
 #define HAVE_KERB4 1
 _ACEOF
 
-                if test "$with_kerb4" = "yes"; then
+                O_LDFLAGS="$LDFLAGS"
+    if test "$with_kerb4" = "yes"; then
        found=no
        O_CPPFLAGS="$CPPFLAGS"
        for dir in "" "kerberosIV/" "krb4/" "kerberos4/" "kerberosv4/"; do
@@ -12433,7 +12529,26 @@ rm -f conftest.err conftest.$ac_ext
        done
        test X"$found" = X"no" && CPPFLAGS="$O_CPPFLAGS"
     else
-       SUDO_LDFLAGS="$LDFLAGS -L${with_kerb4}/lib"
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L${with_kerb4}/lib -R${with_kerb4}/lib"
+    else
+       LDFLAGS="${LDFLAGS} -L${with_kerb4}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_kerb4}/lib"
+    fi
+
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_kerb4}/lib -R${with_kerb4}/lib"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_kerb4}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_kerb4}/lib"
+    fi
+
        CPPFLAGS="$CPPFLAGS -I${with_kerb4}/include"
        if test "${ac_cv_header_krb_h+set}" = set; then
   echo "$as_me:$LINENO: checking for krb.h" >&5
 
 fi
 
-    as_ac_Lib=`echo "ac_cv_lib_krb_main$K4LIBS" | $as_tr_sh`
+                echo "$as_me:$LINENO: checking whether we are using KTH Kerberos IV" >&5
+echo $ECHO_N "checking whether we are using KTH Kerberos IV... $ECHO_C" >&6
+    cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <krb.h>
+int
+main ()
+{
+const char *tmp = krb4_version;
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+
+           echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+           K4LIBS="${K4LIBS} -lcom_err"
+           echo "$as_me:$LINENO: checking for main in -lroken" >&5
+echo $ECHO_N "checking for main in -lroken... $ECHO_C" >&6
+if test "${ac_cv_lib_roken_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lroken  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_roken_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_roken_main=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_roken_main" >&5
+echo "${ECHO_T}$ac_cv_lib_roken_main" >&6
+if test $ac_cv_lib_roken_main = yes; then
+  K4LIBS="${K4LIBS} -lroken"
+fi
+
+
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
+           echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+
+
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+                as_ac_Lib=`echo "ac_cv_lib_krb_main$K4LIBS" | $as_tr_sh`
 echo "$as_me:$LINENO: checking for main in -lkrb" >&5
 echo $ECHO_N "checking for main in -lkrb... $ECHO_C" >&6
 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
@@ -12748,7 +12961,7 @@ fi
 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5
 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
-  K4LIBS="$K4LIBS -lkrb"
+  K4LIBS="-lkrb $K4LIBS"
 else
 
        as_ac_Lib=`echo "ac_cv_lib_krb4_main$K4LIBS" | $as_tr_sh`
@@ -12801,9 +13014,9 @@ fi
 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5
 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
-  K4LIBS="$K4LIBS -lkrb4"
+  K4LIBS="-lkrb4 $K4LIBS"
 else
-  K4LIBS="$K4LIBS -lkrb"
+  K4LIBS="-lkrb $K4LIBS"
            { echo "$as_me:$LINENO: WARNING: Unable to locate Kerberos IV libraries, you will have to edit the Makefile and add -L/path/to/krb/libs to SUDO_LDFLAGS and possibly add Kerberos libs to SUDO_LIBS" >&5
 echo "$as_me: WARNING: Unable to locate Kerberos IV libraries, you will have to edit the Makefile and add -L/path/to/krb/libs to SUDO_LDFLAGS and possibly add Kerberos libs to SUDO_LIBS" >&2;}
 
@@ -12812,6 +13025,7 @@ fi
 
 fi
 
+    LDFLAGS="$O_LDFLAGS"
     SUDO_LIBS="${SUDO_LIBS} $K4LIBS"
     AUTH_OBJS="${AUTH_OBJS} kerb4.o"
 fi
@@ -12862,7 +13076,16 @@ rm -f conftest.err conftest.$ac_ext
 echo "$as_me: WARNING: Unable to locate Kerberos V include files, you will have to edit the Makefile and add -I/path/to/krb/includes to CPPFLAGS" >&2;}
        fi
     else
-               SUDO_LDFLAGS="$LDFLAGS -L${with_kerb5}/lib"
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_kerb5}/lib -R${with_kerb5}/lib"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_kerb5}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_kerb5}/lib"
+    fi
+
        CPPFLAGS="$CPPFLAGS -I${with_kerb5}/include"
     fi
 
@@ -12899,7 +13122,59 @@ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
 
            echo "$as_me:$LINENO: result: yes" >&5
 echo "${ECHO_T}yes" >&6
-           SUDO_LIBS="${SUDO_LIBS} -lkrb5 -ldes -lcom_err -lasn1 -lroken"
+           SUDO_LIBS="${SUDO_LIBS} -lkrb5 -ldes -lcom_err -lasn1"
+           echo "$as_me:$LINENO: checking for main in -lroken" >&5
+echo $ECHO_N "checking for main in -lroken... $ECHO_C" >&6
+if test "${ac_cv_lib_roken_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lroken  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_roken_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_roken_main=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_roken_main" >&5
+echo "${ECHO_T}$ac_cv_lib_roken_main" >&6
+if test $ac_cv_lib_roken_main = yes; then
+  SUDO_LIBS="${SUDO_LIBS} -lroken"
+fi
+
 
 else
   echo "$as_me: failed program was:" >&5
@@ -12980,12 +13255,22 @@ if test "$with_AFS" = "yes"; then
     AFSLIBDIRS="/usr/lib/afs /usr/afsws/lib /usr/afsws/lib/afs"
     for i in $AFSLIBDIRS; do
        if test -d ${i}; then
-           SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${i}"
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L$i -R$i"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L$i"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:$i"
+    fi
+
            FOUND_AFSLIBDIR=true
        fi
     done
     if test -z "$FOUND_AFSLIBDIR"; then
-       echo 'Unable to locate AFS libraries, you will have to edit the Makefile and add -L/path/to/afs/libs to SUDO_LDFLAGS or rerun configure with the --with-libpath options.'
+       { echo "$as_me:$LINENO: WARNING: Unable to locate AFS libraries, you will have to edit the Makefile and add -L/path/to/afs/libs to SUDO_LDFLAGS or rerun configure with the --with-libpath options." >&5
+echo "$as_me: WARNING: Unable to locate AFS libraries, you will have to edit the Makefile and add -L/path/to/afs/libs to SUDO_LDFLAGS or rerun configure with the --with-libpath options." >&2;}
     fi
 
     # Order is important here.  Note that we build AFS_LIBS from right to left
@@ -13012,7 +13297,8 @@ if test "$with_AFS" = "yes"; then
     done
 
     if test -z "$FOUND_AFSLIBDIR"; then
-       echo 'Unable to locate AFS include dir, you may have to edit the Makefile and add -I/path/to/afs/includes to CPPFLAGS or rerun configure with the --with-incpath options.'
+       { echo "$as_me:$LINENO: WARNING: Unable to locate AFS include dir, you may have to edit the Makefile and add -I/path/to/afs/includes to CPPFLAGS or rerun configure with the --with-incpath options." >&5
+echo "$as_me: WARNING: Unable to locate AFS include dir, you may have to edit the Makefile and add -I/path/to/afs/includes to CPPFLAGS or rerun configure with the --with-incpath options." >&2;}
     fi
 fi
 
@@ -13021,19 +13307,182 @@ if test "$with_DCE" = "yes"; then
     SUDO_LIBS="${SUDO_LIBS} -ldce"
 fi
 
-if test "$with_skey" = "yes"; then
-    SUDO_LIBS="${SUDO_LIBS} -lskey"
-    if test -f /usr/include/skey.h -a -f /usr/lib/libskey.a; then
-       :
-    elif test -f /usr/local/include/skey.h; then
-       CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
-       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L/usr/local/lib"
-    elif test "$with_csops" = "yes" -a -f /tools/cs/skey/include/skey.h -a -f /tools/cs/skey/lib/libskey.a; then
-       CPPFLAGS="${CPPFLAGS} -I/tools/cs/skey/include"
-       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L/tools/cs/skey/lib"
+if test -n "$with_skey"; then
+    O_LDFLAGS="$LDFLAGS"
+    if test "$with_skey" != "yes"; then
+       CPPFLAGS="${CPPFLAGS} -I${with_skey}/include"
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L${with_skey}/lib -R${with_skey}/lib"
+    else
+       LDFLAGS="${LDFLAGS} -L${with_skey}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_skey}/lib"
+    fi
+
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_skey}/lib -R${with_skey}/lib"
     else
-       echo 'Unable to locate libskey.a and/or skey.h, you will have to edit the Makefile and add -L/path/to/skey/lib to SUDO_LDFLAGS and/or -I/path/to/skey.h to CPPFLAGS'
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_skey}/lib"
     fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_skey}/lib"
+    fi
+
+       cat >conftest.$ac_ext <<_ACEOF
+#include <skey.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  found=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  found=no
+fi
+rm -f conftest.err conftest.$ac_ext
+    else
+       found=no
+       O_CPPFLAGS="$CPPFLAGS"
+       for dir in "" "/usr/local" "/usr/contrib"; do
+           test -n "$dir" && CPPFLAGS="$O_CPPFLAGS -I${dir}/include"
+           cat >conftest.$ac_ext <<_ACEOF
+#include <skey.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  found=yes; break
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
+fi
+rm -f conftest.err conftest.$ac_ext
+       done
+       if test "$found" = "no" -o -z "$dir"; then
+           CPPFLAGS="$O_CPPFLAGS"
+       else
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L${dir}/lib -R${dir}/lib"
+    else
+       LDFLAGS="${LDFLAGS} -L${dir}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${dir}/lib"
+    fi
+
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${dir}/lib -R${dir}/lib"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${dir}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${dir}/lib"
+    fi
+
+       fi
+    fi
+    if test "$found" = "no"; then
+       { echo "$as_me:$LINENO: WARNING: Unable to locate skey.h, you will have to edit the Makefile and add -I/path/to/skey/includes to CPPFLAGS" >&5
+echo "$as_me: WARNING: Unable to locate skey.h, you will have to edit the Makefile and add -I/path/to/skey/includes to CPPFLAGS" >&2;}
+    fi
+
+echo "$as_me:$LINENO: checking for main in -lskey" >&5
+echo $ECHO_N "checking for main in -lskey... $ECHO_C" >&6
+if test "${ac_cv_lib_skey_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lskey  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_skey_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_skey_main=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_skey_main" >&5
+echo "${ECHO_T}$ac_cv_lib_skey_main" >&6
+if test $ac_cv_lib_skey_main = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define HAVE_LIBSKEY 1
+_ACEOF
+
+  LIBS="-lskey $LIBS"
+
+else
+  { echo "$as_me:$LINENO: WARNING: Unable to locate libskey.a, you will have to edit the Makefile and add -L/path/to/skey/lib to SUDO_LDFLAGS" >&5
+echo "$as_me: WARNING: Unable to locate libskey.a, you will have to edit the Makefile and add -L/path/to/skey/lib to SUDO_LDFLAGS" >&2;}
+fi
+
     echo "$as_me:$LINENO: checking for skeyaccess in -lskey" >&5
 echo $ECHO_N "checking for skeyaccess in -lskey... $ECHO_C" >&6
 if test "${ac_cv_lib_skey_skeyaccess+set}" = set; then
@@ -13096,18 +13545,186 @@ _ACEOF
 
 fi
 
+    LDFLAGS="$O_LDFLAGS"
 fi
 
-if test "$with_opie" = "yes"; then
-    SUDO_LIBS="${SUDO_LIBS} -lopie"
-    if test -f /usr/include/opie.h -a -f /usr/lib/libopie.a; then
-       :
-    elif test -f /usr/local/include/opie.h; then
-       CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
-       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L/usr/local/lib"
+if test -n "$with_opie"; then
+    O_LDFLAGS="$LDFLAGS"
+    if test "$with_opie" != "yes"; then
+       CPPFLAGS="${CPPFLAGS} -I${with_opie}/include"
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L${with_opie}/lib -R${with_opie}/lib"
+    else
+       LDFLAGS="${LDFLAGS} -L${with_opie}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_opie}/lib"
+    fi
+
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_opie}/lib -R${with_opie}/lib"
     else
-       echo 'Unable to locate libopie.a and/or opie.h, you will have to edit the Makefile and add -L/path/to/opie/lib to SUDO_LDFLAGS and/or -I/path/to/opie.h to CPPFLAGS'
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_opie}/lib"
     fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_opie}/lib"
+    fi
+
+       cat >conftest.$ac_ext <<_ACEOF
+#include <opie.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  found=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  found=no
+fi
+rm -f conftest.err conftest.$ac_ext
+    else
+       found=no
+       O_CPPFLAGS="$CPPFLAGS"
+       for dir in "" "/usr/local" "/usr/contrib"; do
+           test -n "$dir" && CPPFLAGS="$O_CPPFLAGS -I${dir}/include"
+           cat >conftest.$ac_ext <<_ACEOF
+#include <opie.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  found=yes; break
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
+fi
+rm -f conftest.err conftest.$ac_ext
+       done
+       if test "$found" = "no" -o -z "$dir"; then
+           CPPFLAGS="$O_CPPFLAGS"
+       else
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L${dir}/lib -R${dir}/lib"
+    else
+       LDFLAGS="${LDFLAGS} -L${dir}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${dir}/lib"
+    fi
+
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${dir}/lib -R${dir}/lib"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${dir}/lib"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${dir}/lib"
+    fi
+
+       fi
+    fi
+    if test "$found" = "no"; then
+       { echo "$as_me:$LINENO: WARNING: Unable to locate opie.h, you will have to edit the Makefile and add -I/path/to/opie/includes to CPPFLAGS" >&5
+echo "$as_me: WARNING: Unable to locate opie.h, you will have to edit the Makefile and add -I/path/to/opie/includes to CPPFLAGS" >&2;}
+    fi
+
+echo "$as_me:$LINENO: checking for main in -lopie" >&5
+echo $ECHO_N "checking for main in -lopie... $ECHO_C" >&6
+if test "${ac_cv_lib_opie_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lopie  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_opie_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_opie_main=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_opie_main" >&5
+echo "${ECHO_T}$ac_cv_lib_opie_main" >&6
+if test $ac_cv_lib_opie_main = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define HAVE_LIBOPIE 1
+_ACEOF
+
+  LIBS="-lopie $LIBS"
+
+else
+  { echo "$as_me:$LINENO: WARNING: Unable to locate libopie.a, you will have to edit the Makefile and add -L/path/to/opie/lib to SUDO_LDFLAGS" >&5
+echo "$as_me: WARNING: Unable to locate libopie.a, you will have to edit the Makefile and add -L/path/to/opie/lib to SUDO_LDFLAGS" >&2;}
+fi
+
+    LDFLAGS="$O_LDFLAGS"
 fi
 
 if test -n "$with_SecurID" -a "$with_SecurID" != "no"; then
@@ -13120,17 +13737,29 @@ if test -n "$with_SecurID" -a "$with_SecurID" != "no"; then
     fi
     CPPFLAGS="${CPPFLAGS} -I${with_SecurID}"
     _LDFLAGS="${LDFLAGS}"
-    LDFLAGS="${LDFLAGS} -L${with_SecurID}"
+
+    if test X"$with_rpath" = X"yes"; then
+       LDFLAGS="${LDFLAGS} -L${with_SecurID} -R${with_SecurID}"
+    else
+       LDFLAGS="${LDFLAGS} -L${with_SecurID}"
+    fi
+    if test X"$blibpath" != X"" -a "LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_SecurID}"
+    fi
+
     #
     # Determine whether to use the new or old SecurID API
     #
     echo "$as_me:$LINENO: checking for SD_Init in -laceclnt" >&5
 echo $ECHO_N "checking for SD_Init in -laceclnt... $ECHO_C" >&6
-if test "${ac_cv_lib_aceclnt_SD_Init_lpthread+set}" = set; then
+if test "${ac_cv_lib_aceclnt_SD_Init_______lpthread_______+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-laceclnt -lpthread $LIBS"
+LIBS="-laceclnt
+           -lpthread
+
+     $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 #line $LINENO "configure"
 /* confdefs.h.  */
@@ -13166,28 +13795,60 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_lib_aceclnt_SD_Init_lpthread=yes
+  ac_cv_lib_aceclnt_SD_Init_______lpthread_______=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_aceclnt_SD_Init_lpthread=no
+ac_cv_lib_aceclnt_SD_Init_______lpthread_______=no
 fi
 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_aceclnt_SD_Init_lpthread" >&5
-echo "${ECHO_T}$ac_cv_lib_aceclnt_SD_Init_lpthread" >&6
-if test $ac_cv_lib_aceclnt_SD_Init_lpthread = yes; then
-  AUTH_OBJS="securid5.o"; SUDO_LIBS="${SUDO_LIBS} -laceclnt -lpthread"; SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_SecurID}"
+echo "$as_me:$LINENO: result: $ac_cv_lib_aceclnt_SD_Init_______lpthread_______" >&5
+echo "${ECHO_T}$ac_cv_lib_aceclnt_SD_Init_______lpthread_______" >&6
+if test $ac_cv_lib_aceclnt_SD_Init_______lpthread_______ = yes; then
+
+           AUTH_OBJS="securid5.o"
+           SUDO_LIBS="${SUDO_LIBS} -laceclnt -lpthread"
+
+
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_SecurID} -R${with_SecurID}"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_SecurID}"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_SecurID}"
+    fi
+
+
 else
-  AUTH_OBJS="securid.o"; SUDO_LIBS="${SUDO_LIBS} ${with_SecurID}/sdiclient.a"
+
+           AUTH_OBJS="securid.o"
+           SUDO_LIBS="${SUDO_LIBS} ${with_SecurID}/sdiclient.a"
+
 fi
 
     LDFLAGS="${_LDFLAGS}"
 fi
 
-if test "$with_fwtk" = "yes"; then
+if test -n "$with_fwtk"; then
+    if test "$with_fwtk" != "yes"; then
+
+    if test X"$with_rpath" = X"yes"; then
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_fwtk} -R${with_fwtk}"
+    else
+       SUDO_LDFLAGS="${SUDO_LDFLAGS} -L${with_fwtk}"
+    fi
+    if test X"$blibpath" != X"" -a "SUDO_LDFLAGS" = "SUDO_LDFLAGS"; then
+       blibpath_add="${blibpath_add}:${with_fwtk}"
+    fi
+
+       CPPFLAGS="${CPPFLAGS} -I${with_fwtk}"
+       with_fwtk=yes
+    fi
     SUDO_LIBS="${SUDO_LIBS} -lauth -lfwall"
 fi
 
@@ -13195,6 +13856,14 @@ if test "$with_authenticate" = "yes"; then
     SUDO_LIBS="${SUDO_LIBS} -ls"
 fi
 
+if test -n "$blibpath"; then
+    if test -n "$blibpath_add"; then
+       SUDO_LDFLAGS="$SUDO_LDFLAGS -Wl,-blibpath:${blibpath}${blibpath_add}"
+    elif test -n "$with_blibpath" -a "$with_blibpath" != "yes"; then
+       SUDO_LDFLAGS="$SUDO_LDFLAGS -Wl,-blibpath:${blibpath}"
+    fi
+fi
+
 echo "$as_me:$LINENO: checking for log file location" >&5
 echo $ECHO_N "checking for log file location... $ECHO_C" >&6
 if test -n "$with_logpath"; then
 
 
 if test "$with_pam" = "yes"; then
-    echo ""
     case $host in
        *-*-linux*)
-           echo "You will need to customize sample.pam and install it as /etc/pam.d/sudo"
+           { echo "$as_me:$LINENO: You will need to customize sample.pam and install it as /etc/pam.d/sudo" >&5
+echo "$as_me: You will need to customize sample.pam and install it as /etc/pam.d/sudo" >&6;}
            ;;
     esac
-    echo ""
 fi