From 1a03de334fd4e6aafb91b806ea35092a7774a8d7 Mon Sep 17 00:00:00 2001 From: Didier Raboud Date: Mon, 19 Jul 2010 15:56:58 +0200 Subject: Imported Upstream version 4.0.4 --- configure.ac | 35 ++++++++++++++++++++++++----------- 1 file changed, 24 insertions(+), 11 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 390902d..7617852 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.61) -AC_INIT(foomatic-rip, "4.0.1") +AC_INIT(foomatic-rip, "4.0.4") AM_INIT_AUTOMAKE([no-define]) AC_CONFIG_SRCDIR([options.c]) @@ -66,14 +66,30 @@ fi # Check for /etc/printcap AC_PATH_DIR(PRINTCAP,printcap,/etc/printcap,$ETCSEARCHPATH) -# Check for /usr/lib/cups -AC_PATH_DIR(CUPS,cups,/usr/lib/cups,$LIBSEARCHPATH) +dnl Check for cups-config +AC_PATH_PROG(CUPS_CONFIG,cups-config) -# Check for /usr/lib/cups/filter -AC_PATH_DIR(CUPS_FILTERS,cups/filter,/usr/lib/cups/filter,$LIBSEARCHPATH) - -# Check for /usr/lib/cups/backend -AC_PATH_DIR(CUPS_BACKENDS,cups/backend,/usr/lib/cups/backend,$LIBSEARCHPATH) +dnl Use cups-config to find CUPS directories +if test -n "$CUPS_CONFIG" && test -z "$CUPS_SERVERBIN"; then + CUPS_SERVERBIN=`cups-config --serverbin 2>/dev/null` +fi +if test -n "$CUPS_SERVERBIN"; then + CUPS=$CUPS_SERVERBIN + CUPS_FILTERS="$CUPS_SERVERBIN/filter" + CUPS_BACKENDS="$CUPS_SERVERBIN/backend" + AC_SUBST(CUPS) + AC_SUBST(CUPS_FILTERS) + AC_SUBST(CUPS_BACKENDS) +else + # Check for /usr/lib/cups + AC_PATH_DIR(CUPS,cups,/usr/lib/cups,$SERVERBIB$LIBSEARCHPATH) + + # Check for /usr/lib/cups/filter + AC_PATH_DIR(CUPS_FILTERS,cups/filter,/usr/lib/cups/filter,$FILTERS$LIBSEARCHPATH) + + # Check for /usr/lib/cups/backend + AC_PATH_DIR(CUPS_BACKENDS,cups/backend,/usr/lib/cups/backend,$BACKENDS$LIBSEARCHPATH) +fi # Check for /usr/lib/ppr AC_PATH_DIR(PPR,ppr,/usr/lib/ppr,$LIBSEARCHPATH) @@ -84,9 +100,6 @@ AC_PATH_DIR(PPR_INTERFACES,ppr/interfaces,/usr/lib/ppr/interfaces,$LIBSEARCHPATH # Check for /usr/lib/ppr/lib AC_PATH_DIR(PPR_LIB,ppr/lib,/usr/lib/ppr/lib,$LIBSEARCHPATH) -AC_CHECK_HEADERS([ghostscript/ierrors.h ghostscript/iapi.h]) -AC_CHECK_LIB(gs, gsapi_new_instance) - AC_ARG_ENABLE(file-converter-check, [ --enable-file-converter-check check whether a file converter is installed [default=yes]], [if eval "test x${enableval} = xno"; then NOCONVERTERCHECK=1 -- cgit v1.2.3