diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2006-10-04 22:31:14 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2006-10-04 22:31:14 +0000 |
| commit | bdef2bf29682ec5c8dcb7bf6083a0c0a13f676c6 (patch) | |
| tree | 4e6e9abcf8579f0654e434a24ba9bf942a336090 /configure.in | |
| parent | 6fa875d7ce918706fc00b7f53a21d67f46a2d837 (diff) | |
| download | postgresql-bdef2bf29682ec5c8dcb7bf6083a0c0a13f676c6.tar.gz | |
Adjust configure's handling of libedit to not look for a history.h file.
Per Bob Friesenhahn's report, this file is not supplied by some versions
of libedit, and even when it is supplied it seems to be just a link to
readline.h, so we don't need to include it anyway.
Also, ensure that we won't try to use a too-old version of Bison.
The previous coding would bleat but then use it anyway; better to invoke
the 'missing' script if any grammar files need to be rebuilt.
Diffstat (limited to 'configure.in')
| -rw-r--r-- | configure.in | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/configure.in b/configure.in index 42b2579fbb..4d182f571b 100644 --- a/configure.in +++ b/configure.in @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -dnl $PostgreSQL: pgsql/configure.in,v 1.479 2006/10/03 22:18:22 tgl Exp $ +dnl $PostgreSQL: pgsql/configure.in,v 1.480 2006/10/04 22:31:13 tgl Exp $ dnl dnl Developers, please strive to achieve this order: dnl @@ -594,25 +594,28 @@ AC_PROG_RANLIB AC_PATH_PROG(TAR, tar) PGAC_CHECK_STRIP -AC_CHECK_PROGS(YACC, ['bison -y']) - -if test "$YACC"; then - if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then - AC_MSG_WARN([ -*** If you are going to modify the grammar files or build from CVS, the installed -*** version of Bison is too old. Bison version 1.875 or later is required.]) +if test -z "$YACC"; then + AC_CHECK_PROGS(YACC, ['bison -y']) + + if test "$YACC"; then + if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then + AC_MSG_WARN([ +*** The installed version of Bison is too old to use with PostgreSQL. +*** Bison version 1.875 or later is required.]) + YACC="" + fi fi -fi -if test -z "$YACC"; then - AC_MSG_WARN([ -*** Without Bison you will not be able to build PostgreSQL from CVS or + if test -z "$YACC"; then + AC_MSG_WARN([ +*** Without Bison you will not be able to build PostgreSQL from CVS nor *** change any of the parser definition files. You can obtain Bison from *** a GNU mirror site. (If you are using the official distribution of -*** 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.) To use a different yacc program (possible, *** but not recommended), set the environment variable YACC before running *** 'configure'.]) + fi fi AC_SUBST(YFLAGS) @@ -753,13 +756,10 @@ if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then If you have libedit already installed, see config.log for details on the failure. It is possible the compiler isn't looking in the proper directory. Use --without-readline to disable libedit support.])])])]) - AC_CHECK_HEADERS(editline/history.h, [], - [AC_CHECK_HEADERS(history.h, [], - [AC_CHECK_HEADERS(readline/history.h, [], - [AC_MSG_ERROR([history header not found -If you have libedit already installed, see config.log for details on the -failure. It is possible the compiler isn't looking in the proper directory. -Use --without-readline to disable libedit support.])])])]) +# Note: in a libedit installation, history.h is normally a dummy, and may +# not be there at all. The functions are declared in readline.h instead. +# To avoid including incompatible headers when both libraries are present, +# assume we do not need history.h. fi if test "$with_zlib" = yes; then |
