Fix the cups checks

This was reported in bug 593712.
This commit is contained in:
Matthias Clasen 2009-08-31 23:59:44 -04:00
parent 0b1a1e200f
commit 036aada543

View File

@ -1873,24 +1873,24 @@ else
AC_SUBST(CUPS_LIBS) AC_SUBST(CUPS_LIBS)
AC_CHECK_HEADER(cups/cups.h,,AC_MSG_ERROR([[*** Sorry, cups-config present but cups/cups.h missing.]])) AC_CHECK_HEADER(cups/cups.h,,AC_MSG_ERROR([[*** Sorry, cups-config present but cups/cups.h missing.]]))
AM_CONDITIONAL(HAVE_CUPS, true)
gtk_save_cflags="$CFLAGS"
CFLAGS="$CUPS_CFLAGS"
AC_TRY_COMPILE([#include <cups/http.h>],
[http_t http; char *s = http.authstring;],
[AC_DEFINE(HAVE_HTTP_AUTHSTRING, [],
[Define if cups http_t authstring field is accessible])],)
CFLAGS="$gtk_save_cflags"
AC_SUBST(HAVE_HTTP_AUTHSTRING)
gtk_save_libs="$LIBS"
LIBS="$CUPS_LIBS"
AC_CHECK_FUNCS(httpGetAuthString)
LIBS="$gtk_save_libs"
fi fi
AM_CONDITIONAL(HAVE_CUPS, true)
gtk_save_cflags="$CFLAGS"
CFLAGS="$CUPS_CFLAGS"
AC_TRY_COMPILE([#include <cups/http.h>],
[http_t http; char *s = http.authstring;],
[AC_DEFINE(HAVE_HTTP_AUTHSTRING, [],
[Define if cups http_t authstring field is accessible])],)
CFLAGS="$gtk_save_cflags"
AC_SUBST(HAVE_HTTP_AUTHSTRING)
gtk_save_libs="$LIBS"
LIBS="$CUPS_LIBS"
AC_CHECK_FUNCS(httpGetAuthString)
LIBS="$gtk_save_libs"
fi fi
# Checks to see if we should compile with PAPI backend for GTK+ # Checks to see if we should compile with PAPI backend for GTK+