dnl
dnl Scripting configuration stuff for CUPS.
dnl
-dnl Copyright 2007-2010 by Apple Inc.
+dnl Copyright 2007-2017 by Apple Inc.
dnl Copyright 1997-2006 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
dnl Do we have Java?
AC_ARG_WITH(java, [ --with-java set Java interpreter for web interfaces ],
CUPS_JAVA="$withval",
- CUPS_JAVA="")
+ CUPS_JAVA="auto")
-if test "x$CUPS_JAVA" = x; then
+if test "x$CUPS_JAVA" = xauto; then
AC_PATH_PROG(JAVA,java)
CUPS_JAVA="$JAVA"
+elif test "x$CUPS_JAVA" = xno; then
+ CUPS_JAVA=""
fi
AC_DEFINE_UNQUOTED(CUPS_JAVA, "$CUPS_JAVA")
dnl Do we have Perl?
AC_ARG_WITH(perl, [ --with-perl set Perl interpreter for web interfaces ],
CUPS_PERL="$withval",
- CUPS_PERL="")
+ CUPS_PERL="auto")
-if test "x$CUPS_PERL" = x; then
+if test "x$CUPS_PERL" = xauto; then
AC_PATH_PROG(PERL,perl)
CUPS_PERL="$PERL"
+elif test "x$CUPS_PERL" = xno; then
+ CUPS_PERL=""
fi
AC_DEFINE_UNQUOTED(CUPS_PERL, "$CUPS_PERL")
dnl Do we have PHP?
AC_ARG_WITH(php, [ --with-php set PHP interpreter for web interfaces ],
CUPS_PHP="$withval",
- CUPS_PHP="")
+ CUPS_PHP="auto")
-if test "x$CUPS_PHP" = x; then
+if test "x$CUPS_PHP" = xauto; then
AC_PATH_PROG(PHPCGI,php-cgi)
if test "x$PHPCGI" = x; then
AC_PATH_PROG(PHP,php)
else
CUPS_PHP="$PHPCGI"
fi
+elif test "x$CUPS_PHP" = xno; then
+ CUPS_PHP=""
fi
AC_DEFINE_UNQUOTED(CUPS_PHP, "$CUPS_PHP")
dnl Do we have Python?
AC_ARG_WITH(python, [ --with-python set Python interpreter for web interfaces ],
CUPS_PYTHON="$withval",
- CUPS_PYTHON="")
+ CUPS_PYTHON="auto")
-if test "x$CUPS_PYTHON" = x; then
+if test "x$CUPS_PYTHON" = xauto; then
AC_PATH_PROG(PYTHON,python)
CUPS_PYTHON="$PYTHON"
+elif test "x$CUPS_PYTHON" = xno; then
+ CUPS_PYTHON=""
fi
AC_DEFINE_UNQUOTED(CUPS_PYTHON, "$CUPS_PYTHON")
SSLFLAGS
IPPALIASES
CUPS_SERVERKEYCHAIN
-LIBGCRYPTCONFIG
LIBGNUTLSCONFIG
PTHREAD_FLAGS
CUPS_DEFAULT_GSSSERVICENAME
LIBGNUTLSCONFIG="$ac_cv_path_LIBGNUTLSCONFIG"
fi
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}libgcrypt-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}libgcrypt-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_LIBGCRYPTCONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $LIBGCRYPTCONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_LIBGCRYPTCONFIG="$LIBGCRYPTCONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_LIBGCRYPTCONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-LIBGCRYPTCONFIG=$ac_cv_path_LIBGCRYPTCONFIG
-if test -n "$LIBGCRYPTCONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGCRYPTCONFIG" >&5
-$as_echo "$LIBGCRYPTCONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_LIBGCRYPTCONFIG"; then
- ac_pt_LIBGCRYPTCONFIG=$LIBGCRYPTCONFIG
- # Extract the first word of "libgcrypt-config", so it can be a program name with args.
-set dummy libgcrypt-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_LIBGCRYPTCONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_LIBGCRYPTCONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_LIBGCRYPTCONFIG="$ac_pt_LIBGCRYPTCONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_LIBGCRYPTCONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_LIBGCRYPTCONFIG=$ac_cv_path_ac_pt_LIBGCRYPTCONFIG
-if test -n "$ac_pt_LIBGCRYPTCONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_LIBGCRYPTCONFIG" >&5
-$as_echo "$ac_pt_LIBGCRYPTCONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_LIBGCRYPTCONFIG" = x; then
- LIBGCRYPTCONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIBGCRYPTCONFIG=$ac_pt_LIBGCRYPTCONFIG
- fi
-else
- LIBGCRYPTCONFIG="$ac_cv_path_LIBGCRYPTCONFIG"
-fi
-
if $PKGCONFIG --exists gnutls; then
have_ssl=1
SSLLIBS=`$PKGCONFIG --libs gnutls`
if test "${with_java+set}" = set; then :
withval=$with_java; CUPS_JAVA="$withval"
else
- CUPS_JAVA=""
+ CUPS_JAVA="auto"
fi
-if test "x$CUPS_JAVA" = x; then
+if test "x$CUPS_JAVA" = xauto; then
# Extract the first word of "java", so it can be a program name with args.
set dummy java; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
CUPS_JAVA="$JAVA"
+elif test "x$CUPS_JAVA" = xno; then
+ CUPS_JAVA=""
fi
cat >>confdefs.h <<_ACEOF
if test "${with_perl+set}" = set; then :
withval=$with_perl; CUPS_PERL="$withval"
else
- CUPS_PERL=""
+ CUPS_PERL="auto"
fi
-if test "x$CUPS_PERL" = x; then
+if test "x$CUPS_PERL" = xauto; then
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
CUPS_PERL="$PERL"
+elif test "x$CUPS_PERL" = xno; then
+ CUPS_PERL=""
fi
cat >>confdefs.h <<_ACEOF
if test "${with_php+set}" = set; then :
withval=$with_php; CUPS_PHP="$withval"
else
- CUPS_PHP=""
+ CUPS_PHP="auto"
fi
-if test "x$CUPS_PHP" = x; then
+if test "x$CUPS_PHP" = xauto; then
# Extract the first word of "php-cgi", so it can be a program name with args.
set dummy php-cgi; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
else
CUPS_PHP="$PHPCGI"
fi
+elif test "x$CUPS_PHP" = xno; then
+ CUPS_PHP=""
fi
cat >>confdefs.h <<_ACEOF
if test "${with_python+set}" = set; then :
withval=$with_python; CUPS_PYTHON="$withval"
else
- CUPS_PYTHON=""
+ CUPS_PYTHON="auto"
fi
-if test "x$CUPS_PYTHON" = x; then
+if test "x$CUPS_PYTHON" = xauto; then
# Extract the first word of "python", so it can be a program name with args.
set dummy python; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
CUPS_PYTHON="$PYTHON"
+elif test "x$CUPS_PYTHON" = xno; then
+ CUPS_PYTHON=""
fi
cat >>confdefs.h <<_ACEOF