+-dnl added by PN 3/2/12 to detect cups
+-$as_echo "checking for cups"
+-if test -e /usr/include/cups/cups.h ; then
+- AC_DEFINE(HAVE_CUPS, 1, [Is /usr/include/cups/cups.h available?])
+- with_cups="yes"
+- LIBS="-lcups $LIBS"
+-else
+- $as_echo "cups.h not found, you may want to install a cups development package"
+- $as_echo "in order to autodetect network scanners in kodakaio."
+- with_cups="no"
++AC_CHECK_HEADERS([cups/cups.h], [with_cups=yes], [with_cups=no])
++if test "x${with_cups}" = "xyes"; then
++ AC_DEFINE(HAVE_CUPS,[1],[Is cups/cups.h available?])
++ AC_PATH_PROG(CUPS_CONFIG, cups-config)
++ if test "x${CUPS_CONFIG}" != "x"; then
++ LIBS="$LIBS `$CUPS_CONFIG --libs`"
++ fi
+ fi