1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-28 23:42:10 +03:00

Remove all traces that suggest that a non-Bison yacc might be supported, and

change build system to use only Bison.  Simplify build rules, make file names
uniform.  Don't build the token table header file where it is not needed.
This commit is contained in:
Peter Eisentraut
2008-08-29 13:02:33 +00:00
parent a2794623d2
commit 7c31742a07
28 changed files with 144 additions and 185 deletions

View File

@ -1,43 +1,41 @@
# $PostgreSQL: pgsql/config/programs.m4,v 1.23 2008/05/27 22:18:04 tgl Exp $
# $PostgreSQL: pgsql/config/programs.m4,v 1.24 2008/08/29 13:02:32 petere Exp $
# PGAC_PATH_YACC
# --------------
# Look for Bison, set the output variable YACC to its path if found.
# PGAC_PATH_BISON
# ---------------
# Look for Bison, set the output variable BISON to its path if found.
# Reject versions before 1.875 (they have bugs or capacity limits).
# Note we do not accept other implementations of yacc.
AC_DEFUN([PGAC_PATH_YACC],
AC_DEFUN([PGAC_PATH_BISON],
[# Let the user override the search
if test -z "$YACC"; then
AC_CHECK_PROGS(YACC, ['bison -y'])
if test -z "$BISON"; then
AC_CHECK_PROGS(BISON, bison)
fi
if test "$YACC"; then
pgac_yacc_version=`$YACC --version 2>/dev/null | sed q`
AC_MSG_NOTICE([using $pgac_yacc_version])
if echo "$pgac_yacc_version" | $AWK '{ if ([$]4 < 1.875) exit 0; else exit 1;}'
if test "$BISON"; then
pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
AC_MSG_NOTICE([using $pgac_bison_version])
if echo "$pgac_bison_version" | $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=""
BISON=""
fi
fi
if test -z "$YACC"; then
if test -z "$BISON"; 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
*** output is pre-generated.) To use a different yacc program (possible,
*** but not recommended), set the environment variable YACC before running
*** 'configure'.])
*** output is pre-generated.)])
fi
# We don't need AC_SUBST(YACC) because AC_PATH_PROG did it
AC_SUBST(YFLAGS)
])# PGAC_PATH_YACC
# We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
AC_SUBST(BISONFLAGS)
])# PGAC_PATH_BISON