Further improve consistency of configure's program searching.

Peter Eisentraut noted that commit 40b9f1921 had broken a configure
behavior that some people might rely on: AC_CHECK_PROGS(FOO,...) will
allow the search to be overridden by specifying a value for FOO on
configure's command line or in its environment, but AC_PATH_PROGS(FOO,...)
accepts such an override only if it's an absolute path.  We had worked
around that behavior for some, but not all, of the pre-existing uses
of AC_PATH_PROGS by just skipping the macro altogether when FOO is
already set.  Let's standardize on that workaround for all uses of
AC_PATH_PROGS, new and pre-existing, by wrapping AC_PATH_PROGS in a
new macro PGAC_PATH_PROGS.  While at it, fix a deficiency of the old
workaround code by making sure we report the setting to configure's log.

Eventually I'd like to improve PGAC_PATH_PROGS so that it converts
non-absolute override inputs to absolute form, eg "PYTHON=python3"
becomes, say, PYTHON = /usr/bin/python3.  But that will take some
nontrivial coding so it doesn't seem like a thing to do in late beta.

Discussion: https://postgr.es/m/90a92a7d-938e-507a-3bd7-ecd2b4004689@2ndquadrant.com
This commit is contained in:
Tom Lane 2017-08-01 11:40:00 -04:00
parent 4de6216877
commit b21c569cea
7 changed files with 267 additions and 52 deletions

View File

@ -3,7 +3,7 @@
# PGAC_PROG_NSGMLS # PGAC_PROG_NSGMLS
# ---------------- # ----------------
AC_DEFUN([PGAC_PROG_NSGMLS], AC_DEFUN([PGAC_PROG_NSGMLS],
[AC_PATH_PROGS([NSGMLS], [onsgmls nsgmls])]) [PGAC_PATH_PROGS(NSGMLS, [onsgmls nsgmls])])
# PGAC_CHECK_DOCBOOK(VERSION) # PGAC_CHECK_DOCBOOK(VERSION)

View File

@ -4,10 +4,7 @@
# PGAC_PATH_PERL # PGAC_PATH_PERL
# -------------- # --------------
AC_DEFUN([PGAC_PATH_PERL], AC_DEFUN([PGAC_PATH_PERL],
[# Let the user override the search [PGAC_PATH_PROGS(PERL, perl)
if test -z "$PERL"; then
AC_PATH_PROG(PERL, perl)
fi
if test "$PERL"; then if test "$PERL"; then
pgac_perl_version=`$PERL -v 2>/dev/null | sed -n ['s/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p']` pgac_perl_version=`$PERL -v 2>/dev/null | sed -n ['s/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p']`

View File

@ -1,6 +1,24 @@
# config/programs.m4 # config/programs.m4
# PGAC_PATH_PROGS
# ---------------
# This wrapper for AC_PATH_PROGS behaves like that macro except when
# VARIABLE is already set; in that case we just accept the value verbatim.
# (AC_PATH_PROGS would accept it only if it looks like an absolute path.)
# A desirable future improvement would be to convert a non-absolute-path
# input into absolute form.
AC_DEFUN([PGAC_PATH_PROGS],
[if test -z "$$1"; then
AC_PATH_PROGS($@)
else
# Report the value of $1 in configure's output in all cases.
AC_MSG_CHECKING([for $1])
AC_MSG_RESULT([$$1])
fi
])
# PGAC_PATH_BISON # PGAC_PATH_BISON
# --------------- # ---------------
# Look for Bison, set the output variable BISON to its path if found. # Look for Bison, set the output variable BISON to its path if found.
@ -8,10 +26,7 @@
# Note we do not accept other implementations of yacc. # Note we do not accept other implementations of yacc.
AC_DEFUN([PGAC_PATH_BISON], AC_DEFUN([PGAC_PATH_BISON],
[# Let the user override the search [PGAC_PATH_PROGS(BISON, bison)
if test -z "$BISON"; then
AC_PATH_PROGS(BISON, bison)
fi
if test "$BISON"; then if test "$BISON"; then
pgac_bison_version=`$BISON --version 2>/dev/null | sed q` pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
@ -41,7 +56,7 @@ if test -z "$BISON"; then
*** PostgreSQL then you do not need to worry about this, because the Bison *** PostgreSQL then you do not need to worry about this, because the Bison
*** output is pre-generated.)]) *** output is pre-generated.)])
fi fi
# We don't need AC_SUBST(BISON) because AC_PATH_PROG did it # We don't need AC_SUBST(BISON) because PGAC_PATH_PROGS did it
AC_SUBST(BISONFLAGS) AC_SUBST(BISONFLAGS)
])# PGAC_PATH_BISON ])# PGAC_PATH_BISON
@ -229,7 +244,7 @@ AC_DEFUN([PGAC_CHECK_GETTEXT],
[AC_MSG_ERROR([a gettext implementation is required for NLS])]) [AC_MSG_ERROR([a gettext implementation is required for NLS])])
AC_CHECK_HEADER([libintl.h], [], AC_CHECK_HEADER([libintl.h], [],
[AC_MSG_ERROR([header file <libintl.h> is required for NLS])]) [AC_MSG_ERROR([header file <libintl.h> is required for NLS])])
AC_PATH_PROGS(MSGFMT, msgfmt) PGAC_PATH_PROGS(MSGFMT, msgfmt)
if test -z "$MSGFMT"; then if test -z "$MSGFMT"; then
AC_MSG_ERROR([msgfmt is required for NLS]) AC_MSG_ERROR([msgfmt is required for NLS])
fi fi
@ -238,8 +253,8 @@ AC_DEFUN([PGAC_CHECK_GETTEXT],
pgac_cv_msgfmt_flags=-c pgac_cv_msgfmt_flags=-c
fi]) fi])
AC_SUBST(MSGFMT_FLAGS, $pgac_cv_msgfmt_flags) AC_SUBST(MSGFMT_FLAGS, $pgac_cv_msgfmt_flags)
AC_PATH_PROGS(MSGMERGE, msgmerge) PGAC_PATH_PROGS(MSGMERGE, msgmerge)
AC_PATH_PROGS(XGETTEXT, xgettext) PGAC_PATH_PROGS(XGETTEXT, xgettext)
])# PGAC_CHECK_GETTEXT ])# PGAC_CHECK_GETTEXT

View File

@ -6,10 +6,10 @@
# PGAC_PATH_PYTHON # PGAC_PATH_PYTHON
# ---------------- # ----------------
# Look for Python and set the output variable 'PYTHON' # Look for Python and set the output variable 'PYTHON' if found,
# to 'python' if found, empty otherwise. # fail otherwise.
AC_DEFUN([PGAC_PATH_PYTHON], AC_DEFUN([PGAC_PATH_PYTHON],
[AC_PATH_PROG(PYTHON, python) [PGAC_PATH_PROGS(PYTHON, python)
if test x"$PYTHON" = x""; then if test x"$PYTHON" = x""; then
AC_MSG_ERROR([Python not found]) AC_MSG_ERROR([Python not found])
fi fi

View File

@ -4,7 +4,7 @@
AC_DEFUN([PGAC_PATH_TCLSH], AC_DEFUN([PGAC_PATH_TCLSH],
[AC_PATH_PROGS(TCLSH, [tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84]) [PGAC_PATH_PROGS(TCLSH, [tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84])
if test x"$TCLSH" = x""; then if test x"$TCLSH" = x""; then
AC_MSG_ERROR([Tcl shell not found]) AC_MSG_ERROR([Tcl shell not found])
fi fi

247
configure vendored
View File

@ -3298,7 +3298,8 @@ if test "${enable_coverage+set}" = set; then :
enableval=$enable_coverage; enableval=$enable_coverage;
case $enableval in case $enableval in
yes) yes)
for ac_prog in gcov if test -z "$GCOV"; then
for ac_prog in gcov
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -3343,10 +3344,19 @@ fi
test -n "$GCOV" && break test -n "$GCOV" && break
done done
else
# Report the value of GCOV in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GCOV" >&5
$as_echo_n "checking for GCOV... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
$as_echo "$GCOV" >&6; }
fi
if test -z "$GCOV"; then if test -z "$GCOV"; then
as_fn_error $? "gcov not found" "$LINENO" 5 as_fn_error $? "gcov not found" "$LINENO" 5
fi fi
for ac_prog in lcov if test -z "$LCOV"; then
for ac_prog in lcov
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -3391,10 +3401,19 @@ fi
test -n "$LCOV" && break test -n "$LCOV" && break
done done
else
# Report the value of LCOV in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCOV" >&5
$as_echo_n "checking for LCOV... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
$as_echo "$LCOV" >&6; }
fi
if test -z "$LCOV"; then if test -z "$LCOV"; then
as_fn_error $? "lcov not found" "$LINENO" 5 as_fn_error $? "lcov not found" "$LINENO" 5
fi fi
for ac_prog in genhtml if test -z "$GENHTML"; then
for ac_prog in genhtml
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -3439,6 +3458,14 @@ fi
test -n "$GENHTML" && break test -n "$GENHTML" && break
done done
else
# Report the value of GENHTML in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GENHTML" >&5
$as_echo_n "checking for GENHTML... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
$as_echo "$GENHTML" >&6; }
fi
if test -z "$GENHTML"; then if test -z "$GENHTML"; then
as_fn_error $? "genhtml not found" "$LINENO" 5 as_fn_error $? "genhtml not found" "$LINENO" 5
fi fi
@ -3469,7 +3496,8 @@ if test "${enable_dtrace+set}" = set; then :
enableval=$enable_dtrace; enableval=$enable_dtrace;
case $enableval in case $enableval in
yes) yes)
for ac_prog in dtrace if test -z "$DTRACE"; then
for ac_prog in dtrace
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -3514,6 +3542,14 @@ fi
test -n "$DTRACE" && break test -n "$DTRACE" && break
done done
else
# Report the value of DTRACE in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5
$as_echo_n "checking for DTRACE... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
$as_echo "$DTRACE" >&6; }
fi
if test -z "$DTRACE"; then if test -z "$DTRACE"; then
as_fn_error $? "dtrace not found" "$LINENO" 5 as_fn_error $? "dtrace not found" "$LINENO" 5
fi fi
@ -6266,6 +6302,7 @@ fi
if test "$with_libxml" = yes ; then if test "$with_libxml" = yes ; then
if test -z "$XML2_CONFIG"; then
for ac_prog in xml2-config for ac_prog in xml2-config
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
@ -6311,6 +6348,14 @@ fi
test -n "$XML2_CONFIG" && break test -n "$XML2_CONFIG" && break
done done
else
# Report the value of XML2_CONFIG in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML2_CONFIG" >&5
$as_echo_n "checking for XML2_CONFIG... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
$as_echo "$XML2_CONFIG" >&6; }
fi
if test -n "$XML2_CONFIG"; then if test -n "$XML2_CONFIG"; then
for pgac_option in `$XML2_CONFIG --cflags`; do for pgac_option in `$XML2_CONFIG --cflags`; do
case $pgac_option in case $pgac_option in
@ -7374,8 +7419,11 @@ case $INSTALL in
esac esac
# Extract the first word of "tar", so it can be a program name with args. if test -z "$TAR"; then
set dummy tar; ac_word=$2 for ac_prog in tar
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; } $as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_path_TAR+:} false; then : if ${ac_cv_path_TAR+:} false; then :
@ -7414,6 +7462,17 @@ $as_echo "no" >&6; }
fi fi
test -n "$TAR" && break
done
else
# Report the value of TAR in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
$as_echo_n "checking for TAR... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
$as_echo "$TAR" >&6; }
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
$as_echo_n "checking whether ln -s works... " >&6; } $as_echo_n "checking whether ln -s works... " >&6; }
LN_S=$as_ln_s LN_S=$as_ln_s
@ -7516,7 +7575,6 @@ case $MKDIR_P in
*install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';; *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
esac esac
# Let the user override the search
if test -z "$BISON"; then if test -z "$BISON"; then
for ac_prog in bison for ac_prog in bison
do do
@ -7563,8 +7621,15 @@ fi
test -n "$BISON" && break test -n "$BISON" && break
done done
else
# Report the value of BISON in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BISON" >&5
$as_echo_n "checking for BISON... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
$as_echo "$BISON" >&6; }
fi fi
if test "$BISON"; then if test "$BISON"; then
pgac_bison_version=`$BISON --version 2>/dev/null | sed q` pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
{ $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_bison_version" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_bison_version" >&5
@ -7603,7 +7668,7 @@ $as_echo "$as_me: WARNING:
*** PostgreSQL then you do not need to worry about this, because the Bison *** PostgreSQL then you do not need to worry about this, because the Bison
*** output is pre-generated.)" >&2;} *** output is pre-generated.)" >&2;}
fi fi
# We don't need AC_SUBST(BISON) because AC_PATH_PROG did it # We don't need AC_SUBST(BISON) because PGAC_PATH_PROGS did it
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex" >&5
@ -7679,10 +7744,11 @@ fi
# Let the user override the search
if test -z "$PERL"; then if test -z "$PERL"; then
# Extract the first word of "perl", so it can be a program name with args. for ac_prog in perl
set dummy perl; ac_word=$2 do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; } $as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_path_PERL+:} false; then : if ${ac_cv_path_PERL+:} false; then :
@ -7721,8 +7787,18 @@ $as_echo "no" >&6; }
fi fi
test -n "$PERL" && break
done
else
# Report the value of PERL in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PERL" >&5
$as_echo_n "checking for PERL... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
$as_echo "$PERL" >&6; }
fi fi
if test "$PERL"; then if test "$PERL"; then
pgac_perl_version=`$PERL -v 2>/dev/null | sed -n 's/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p'` pgac_perl_version=`$PERL -v 2>/dev/null | sed -n 's/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p'`
{ $as_echo "$as_me:${as_lineno-$LINENO}: using perl $pgac_perl_version" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: using perl $pgac_perl_version" >&5
@ -7819,8 +7895,11 @@ fi
fi fi
if test "$with_python" = yes; then if test "$with_python" = yes; then
# Extract the first word of "python", so it can be a program name with args. if test -z "$PYTHON"; then
set dummy python; ac_word=$2 for ac_prog in python
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; } $as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_path_PYTHON+:} false; then : if ${ac_cv_path_PYTHON+:} false; then :
@ -7859,6 +7938,17 @@ $as_echo "no" >&6; }
fi fi
test -n "$PYTHON" && break
done
else
# Report the value of PYTHON in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PYTHON" >&5
$as_echo_n "checking for PYTHON... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
$as_echo "$PYTHON" >&6; }
fi
if test x"$PYTHON" = x""; then if test x"$PYTHON" = x""; then
as_fn_error $? "Python not found" "$LINENO" 5 as_fn_error $? "Python not found" "$LINENO" 5
fi fi
@ -7997,8 +8087,11 @@ $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
fi fi
if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
# Extract the first word of "zic", so it can be a program name with args. if test -z "$ZIC"; then
set dummy zic; ac_word=$2 for ac_prog in zic
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; } $as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_path_ZIC+:} false; then : if ${ac_cv_path_ZIC+:} false; then :
@ -8037,6 +8130,17 @@ $as_echo "no" >&6; }
fi fi
test -n "$ZIC" && break
done
else
# Report the value of ZIC in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIC" >&5
$as_echo_n "checking for ZIC... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
$as_echo "$ZIC" >&6; }
fi
if test -z "$ZIC"; then if test -z "$ZIC"; then
as_fn_error $? " as_fn_error $? "
When cross-compiling, either use the option --with-system-tzdata to use When cross-compiling, either use the option --with-system-tzdata to use
@ -15614,6 +15718,7 @@ else
fi fi
if test -z "$MSGFMT"; then
for ac_prog in msgfmt for ac_prog in msgfmt
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
@ -15659,6 +15764,14 @@ fi
test -n "$MSGFMT" && break test -n "$MSGFMT" && break
done done
else
# Report the value of MSGFMT in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGFMT" >&5
$as_echo_n "checking for MSGFMT... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
$as_echo "$MSGFMT" >&6; }
fi
if test -z "$MSGFMT"; then if test -z "$MSGFMT"; then
as_fn_error $? "msgfmt is required for NLS" "$LINENO" 5 as_fn_error $? "msgfmt is required for NLS" "$LINENO" 5
fi fi
@ -15675,6 +15788,7 @@ fi
$as_echo "$pgac_cv_msgfmt_flags" >&6; } $as_echo "$pgac_cv_msgfmt_flags" >&6; }
MSGFMT_FLAGS=$pgac_cv_msgfmt_flags MSGFMT_FLAGS=$pgac_cv_msgfmt_flags
if test -z "$MSGMERGE"; then
for ac_prog in msgmerge for ac_prog in msgmerge
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
@ -15720,6 +15834,15 @@ fi
test -n "$MSGMERGE" && break test -n "$MSGMERGE" && break
done done
else
# Report the value of MSGMERGE in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGMERGE" >&5
$as_echo_n "checking for MSGMERGE... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
$as_echo "$MSGMERGE" >&6; }
fi
if test -z "$XGETTEXT"; then
for ac_prog in xgettext for ac_prog in xgettext
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
@ -15765,12 +15888,21 @@ fi
test -n "$XGETTEXT" && break test -n "$XGETTEXT" && break
done done
else
# Report the value of XGETTEXT in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for XGETTEXT" >&5
$as_echo_n "checking for XGETTEXT... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
$as_echo "$XGETTEXT" >&6; }
fi
fi fi
# Check for Tcl configuration script tclConfig.sh # Check for Tcl configuration script tclConfig.sh
if test "$with_tcl" = yes; then if test "$with_tcl" = yes; then
for ac_prog in tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84 if test -z "$TCLSH"; then
for ac_prog in tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -15815,6 +15947,14 @@ fi
test -n "$TCLSH" && break test -n "$TCLSH" && break
done done
else
# Report the value of TCLSH in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TCLSH" >&5
$as_echo_n "checking for TCLSH... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
$as_echo "$TCLSH" >&6; }
fi
if test x"$TCLSH" = x""; then if test x"$TCLSH" = x""; then
as_fn_error $? "Tcl shell not found" "$LINENO" 5 as_fn_error $? "Tcl shell not found" "$LINENO" 5
fi fi
@ -15941,7 +16081,8 @@ fi
# #
# Check for DocBook and tools # Check for DocBook and tools
# #
for ac_prog in onsgmls nsgmls if test -z "$NSGMLS"; then
for ac_prog in onsgmls nsgmls
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -15986,6 +16127,14 @@ fi
test -n "$NSGMLS" && break test -n "$NSGMLS" && break
done done
else
# Report the value of NSGMLS in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for NSGMLS" >&5
$as_echo_n "checking for NSGMLS... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $NSGMLS" >&5
$as_echo "$NSGMLS" >&6; }
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for DocBook V4.2" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DocBook V4.2" >&5
$as_echo_n "checking for DocBook V4.2... " >&6; } $as_echo_n "checking for DocBook V4.2... " >&6; }
@ -16022,7 +16171,8 @@ $as_echo "$pgac_cv_check_docbook" >&6; }
have_docbook=$pgac_cv_check_docbook have_docbook=$pgac_cv_check_docbook
for ac_prog in dbtoepub if test -z "$DBTOEPUB"; then
for ac_prog in dbtoepub
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -16067,7 +16217,16 @@ fi
test -n "$DBTOEPUB" && break test -n "$DBTOEPUB" && break
done done
for ac_prog in xmllint else
# Report the value of DBTOEPUB in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for DBTOEPUB" >&5
$as_echo_n "checking for DBTOEPUB... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
$as_echo "$DBTOEPUB" >&6; }
fi
if test -z "$XMLLINT"; then
for ac_prog in xmllint
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -16112,7 +16271,16 @@ fi
test -n "$XMLLINT" && break test -n "$XMLLINT" && break
done done
for ac_prog in xsltproc else
# Report the value of XMLLINT in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for XMLLINT" >&5
$as_echo_n "checking for XMLLINT... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
$as_echo "$XMLLINT" >&6; }
fi
if test -z "$XSLTPROC"; then
for ac_prog in xsltproc
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -16157,7 +16325,16 @@ fi
test -n "$XSLTPROC" && break test -n "$XSLTPROC" && break
done done
for ac_prog in osx sgml2xml sx else
# Report the value of XSLTPROC in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for XSLTPROC" >&5
$as_echo_n "checking for XSLTPROC... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
$as_echo "$XSLTPROC" >&6; }
fi
if test -z "$OSX"; then
for ac_prog in osx sgml2xml sx
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -16202,7 +16379,16 @@ fi
test -n "$OSX" && break test -n "$OSX" && break
done done
for ac_prog in fop else
# Report the value of OSX in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX" >&5
$as_echo_n "checking for OSX... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $OSX" >&5
$as_echo "$OSX" >&6; }
fi
if test -z "$FOP"; then
for ac_prog in fop
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2 set dummy $ac_prog; ac_word=$2
@ -16247,11 +16433,20 @@ fi
test -n "$FOP" && break test -n "$FOP" && break
done done
else
# Report the value of FOP in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FOP" >&5
$as_echo_n "checking for FOP... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
$as_echo "$FOP" >&6; }
fi
# #
# Check for test tools # Check for test tools
# #
if test "$enable_tap_tests" = yes; then if test "$enable_tap_tests" = yes; then
if test -z "$PROVE"; then
for ac_prog in prove for ac_prog in prove
do do
# Extract the first word of "$ac_prog", so it can be a program name with args. # Extract the first word of "$ac_prog", so it can be a program name with args.
@ -16297,6 +16492,14 @@ fi
test -n "$PROVE" && break test -n "$PROVE" && break
done done
else
# Report the value of PROVE in configure's output in all cases.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PROVE" >&5
$as_echo_n "checking for PROVE... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
$as_echo "$PROVE" >&6; }
fi
if test -z "$PROVE"; then if test -z "$PROVE"; then
as_fn_error $? "prove not found" "$LINENO" 5 as_fn_error $? "prove not found" "$LINENO" 5
fi fi

View File

@ -218,15 +218,15 @@ PGAC_ARG_BOOL(enable, profiling, no,
# #
PGAC_ARG_BOOL(enable, coverage, no, PGAC_ARG_BOOL(enable, coverage, no,
[build with coverage testing instrumentation], [build with coverage testing instrumentation],
[AC_PATH_PROGS(GCOV, gcov) [PGAC_PATH_PROGS(GCOV, gcov)
if test -z "$GCOV"; then if test -z "$GCOV"; then
AC_MSG_ERROR([gcov not found]) AC_MSG_ERROR([gcov not found])
fi fi
AC_PATH_PROGS(LCOV, lcov) PGAC_PATH_PROGS(LCOV, lcov)
if test -z "$LCOV"; then if test -z "$LCOV"; then
AC_MSG_ERROR([lcov not found]) AC_MSG_ERROR([lcov not found])
fi fi
AC_PATH_PROGS(GENHTML, genhtml) PGAC_PATH_PROGS(GENHTML, genhtml)
if test -z "$GENHTML"; then if test -z "$GENHTML"; then
AC_MSG_ERROR([genhtml not found]) AC_MSG_ERROR([genhtml not found])
fi]) fi])
@ -237,7 +237,7 @@ AC_SUBST(enable_coverage)
# #
PGAC_ARG_BOOL(enable, dtrace, no, PGAC_ARG_BOOL(enable, dtrace, no,
[build with DTrace support], [build with DTrace support],
[AC_PATH_PROGS(DTRACE, dtrace) [PGAC_PATH_PROGS(DTRACE, dtrace)
if test -z "$DTRACE"; then if test -z "$DTRACE"; then
AC_MSG_ERROR([dtrace not found]) AC_MSG_ERROR([dtrace not found])
fi fi
@ -816,7 +816,7 @@ PGAC_ARG_BOOL(with, libxml, no, [build with XML support],
[AC_DEFINE([USE_LIBXML], 1, [Define to 1 to build with XML support. (--with-libxml)])]) [AC_DEFINE([USE_LIBXML], 1, [Define to 1 to build with XML support. (--with-libxml)])])
if test "$with_libxml" = yes ; then if test "$with_libxml" = yes ; then
AC_PATH_PROGS(XML2_CONFIG, xml2-config) PGAC_PATH_PROGS(XML2_CONFIG, xml2-config)
if test -n "$XML2_CONFIG"; then if test -n "$XML2_CONFIG"; then
for pgac_option in `$XML2_CONFIG --cflags`; do for pgac_option in `$XML2_CONFIG --cflags`; do
case $pgac_option in case $pgac_option in
@ -912,7 +912,7 @@ case $INSTALL in
esac esac
AC_SUBST(install_bin) AC_SUBST(install_bin)
AC_PATH_PROG(TAR, tar) PGAC_PATH_PROGS(TAR, tar)
AC_PROG_LN_S AC_PROG_LN_S
AC_PROG_AWK AC_PROG_AWK
AC_PROG_MKDIR_P AC_PROG_MKDIR_P
@ -948,7 +948,7 @@ if test "$with_python" = yes; then
fi fi
if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
AC_PATH_PROG(ZIC, zic) PGAC_PATH_PROGS(ZIC, zic)
if test -z "$ZIC"; then if test -z "$ZIC"; then
AC_MSG_ERROR([ AC_MSG_ERROR([
When cross-compiling, either use the option --with-system-tzdata to use When cross-compiling, either use the option --with-system-tzdata to use
@ -2119,17 +2119,17 @@ fi
# #
PGAC_PROG_NSGMLS PGAC_PROG_NSGMLS
PGAC_CHECK_DOCBOOK(4.2) PGAC_CHECK_DOCBOOK(4.2)
AC_PATH_PROGS(DBTOEPUB, dbtoepub) PGAC_PATH_PROGS(DBTOEPUB, dbtoepub)
AC_PATH_PROGS(XMLLINT, xmllint) PGAC_PATH_PROGS(XMLLINT, xmllint)
AC_PATH_PROGS(XSLTPROC, xsltproc) PGAC_PATH_PROGS(XSLTPROC, xsltproc)
AC_PATH_PROGS(OSX, [osx sgml2xml sx]) PGAC_PATH_PROGS(OSX, [osx sgml2xml sx])
AC_PATH_PROGS(FOP, fop) PGAC_PATH_PROGS(FOP, fop)
# #
# Check for test tools # Check for test tools
# #
if test "$enable_tap_tests" = yes; then if test "$enable_tap_tests" = yes; then
AC_PATH_PROGS(PROVE, prove) PGAC_PATH_PROGS(PROVE, prove)
if test -z "$PROVE"; then if test -z "$PROVE"; then
AC_MSG_ERROR([prove not found]) AC_MSG_ERROR([prove not found])
fi fi