If libdir is /usr/lib, don't add the -L argument to the library flags
authorKen Raeburn <raeburn@mit.edu>
Sat, 25 Aug 2007 09:03:36 +0000 (09:03 +0000)
committerKen Raeburn <raeburn@mit.edu>
Sat, 25 Aug 2007 09:03:36 +0000 (09:03 +0000)
to be output.

ticket: 5657

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19879 dc483132-0cff-0310-8789-dd5450dbe970

src/krb5-config.in

index 341450cd282f0f5e6d5a8e035d1373e8b6c240df..9b55e808b8701f788a9b7740058d7857e43d7dcf 100755 (executable)
@@ -176,11 +176,17 @@ fi
 
 
 if test -n "$do_libs"; then
+    # Assumes /usr/lib is the standard library directory everywhere...
+    if test "$libdir" = /usr/lib; then
+       libdirarg=
+    else
+       libdirarg="-L$libdir"
+    fi
     # Ugly gross hack for our build tree
     lib_flags=`echo $CC_LINK | sed -e 's/\$(CC)//' \
            -e 's/\$(PURE)//' \
            -e 's#\$(PROG_RPATH)#'$libdir'#' \
-           -e 's#\$(PROG_LIBPATH)#-L'$libdir'#' \
+           -e 's#\$(PROG_LIBPATH)#'$libdirarg'#' \
            -e 's#\$(RPATH_FLAG)#'"$RPATH_FLAG"'#' \
            -e 's#\$(LDFLAGS)#'"$LDFLAGS"'#' \
            -e 's#\$(PTHREAD_CFLAGS)#'"$PTHREAD_CFLAGS"'#' \