summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2014-06-15 12:42:30 +0200
committerDaniel Stenberg <daniel@haxx.se>2014-07-14 20:49:28 +0200
commit08b27e08926bce16a451ca502391457c8ae8c1b7 (patch)
treecd839c6a0d5066b9a14f51dbad43f4f00ec7a6f9
parent98866008a98da437998f72d38be06495cf91d319 (diff)
downloadgnurl-08b27e08926bce16a451ca502391457c8ae8c1b7.tar.gz
gnurl-08b27e08926bce16a451ca502391457c8ae8c1b7.tar.bz2
gnurl-08b27e08926bce16a451ca502391457c8ae8c1b7.zip
configure: respect host tool prefix for krb5-config
Use ${host_alias}-krb5-config if available. This improves cross- compilation support and fixes multilib on Gentoo (at least).
-rw-r--r--configure.ac11
1 files changed, 9 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index e8d322a02..dd014b725 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1209,7 +1209,9 @@ if test x"$want_gss" = xyes; then
AC_MSG_RESULT(yes)
if test -z "$GSSAPI_INCS"; then
- if test -f "$GSSAPI_ROOT/bin/krb5-config"; then
+ if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then
+ GSSAPI_INCS=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --cflags gssapi`
+ elif test -f "$GSSAPI_ROOT/bin/krb5-config"; then
GSSAPI_INCS=`$GSSAPI_ROOT/bin/krb5-config --cflags gssapi`
elif test "$GSSAPI_ROOT" != "yes"; then
GSSAPI_INCS="-I$GSSAPI_ROOT/include"
@@ -1301,7 +1303,12 @@ if test x"$want_gss" = xyes; then
LIBS="-lgss $LIBS"
;;
*)
- if test -f "$GSSAPI_ROOT/bin/krb5-config"; then
+ if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then
+ dnl krb5-config doesn't have --libs-only-L or similar, put everything
+ dnl into LIBS
+ gss_libs=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --libs gssapi`
+ LIBS="$gss_libs $LIBS"
+ elif test -f "$GSSAPI_ROOT/bin/krb5-config"; then
dnl krb5-config doesn't have --libs-only-L or similar, put everything
dnl into LIBS
gss_libs=`$GSSAPI_ROOT/bin/krb5-config --libs gssapi`