mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +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:
@@ -1,3 +1,3 @@
|
||||
parse.h
|
||||
gram.h
|
||||
gram.c
|
||||
scan.c
|
||||
|
@@ -2,7 +2,7 @@
|
||||
#
|
||||
# Makefile for parser
|
||||
#
|
||||
# $PostgreSQL: pgsql/src/backend/parser/Makefile,v 1.46 2008/02/19 10:30:07 petere Exp $
|
||||
# $PostgreSQL: pgsql/src/backend/parser/Makefile,v 1.47 2008/08/29 13:02:32 petere Exp $
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
@@ -32,13 +32,11 @@ gram.o: $(srcdir)/scan.c
|
||||
# important, otherwise make will choose the built-in rule for
|
||||
# gram.y=>gram.c.
|
||||
|
||||
$(srcdir)/gram.c: $(srcdir)/parse.h ;
|
||||
$(srcdir)/gram.h: $(srcdir)/gram.c ;
|
||||
|
||||
$(srcdir)/parse.h: gram.y
|
||||
ifdef YACC
|
||||
$(YACC) -d $(YFLAGS) $<
|
||||
mv -f y.tab.c $(srcdir)/gram.c
|
||||
mv -f y.tab.h $(srcdir)/parse.h
|
||||
$(srcdir)/gram.c: gram.y
|
||||
ifdef BISON
|
||||
$(BISON) -d $(BISONFLAGS) -o $@ $<
|
||||
else
|
||||
@$(missing) bison $< $@
|
||||
endif
|
||||
@@ -53,11 +51,8 @@ endif
|
||||
|
||||
|
||||
# Force these dependencies to be known even without dependency info built:
|
||||
gram.o keywords.o parser.o: $(srcdir)/parse.h
|
||||
gram.o keywords.o parser.o: $(srcdir)/gram.h
|
||||
|
||||
|
||||
# gram.c, parse.h, and scan.c are in the distribution tarball, so they
|
||||
# gram.c, gram.h, and scan.c are in the distribution tarball, so they
|
||||
# are not cleaned here.
|
||||
clean:
|
||||
# And the garbage that might have been left behind by partial build:
|
||||
@rm -f y.tab.h y.tab.c y.output lex.yy.c
|
||||
|
@@ -11,7 +11,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/parser/keywords.c,v 1.199 2008/07/16 01:30:22 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/parser/keywords.c,v 1.200 2008/08/29 13:02:32 petere Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -22,7 +22,7 @@
|
||||
#include <ctype.h>
|
||||
|
||||
/*
|
||||
* This macro definition overrides the YYSTYPE union definition in parse.h.
|
||||
* This macro definition overrides the YYSTYPE union definition in gram.h.
|
||||
* We don't need that struct in this file, and including the real definition
|
||||
* would require sucking in some backend-only include files.
|
||||
*/
|
||||
@@ -30,7 +30,7 @@
|
||||
|
||||
#include "parser/keywords.h"
|
||||
#ifndef ECPG_COMPILE
|
||||
#include "parser/parse.h"
|
||||
#include "parser/gram.h"
|
||||
#else
|
||||
#include "preproc.h"
|
||||
#endif
|
||||
|
@@ -14,15 +14,15 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/parser/parser.c,v 1.73 2008/01/01 19:45:51 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/parser/parser.c,v 1.74 2008/08/29 13:02:32 petere Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
|
||||
#include "postgres.h"
|
||||
|
||||
#include "parser/gramparse.h" /* required before parser/parse.h! */
|
||||
#include "parser/parse.h"
|
||||
#include "parser/gramparse.h" /* required before parser/gram.h! */
|
||||
#include "parser/gram.h"
|
||||
#include "parser/parser.h"
|
||||
|
||||
|
||||
|
@@ -24,7 +24,7 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/parser/scan.l,v 1.144 2008/05/09 15:36:31 petere Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/parser/scan.l,v 1.145 2008/08/29 13:02:32 petere Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -36,7 +36,7 @@
|
||||
#include "parser/gramparse.h"
|
||||
#include "parser/keywords.h"
|
||||
/* Not needed now that this file is compiled as part of gram.y */
|
||||
/* #include "parser/parse.h" */
|
||||
/* #include "parser/gram.h" */
|
||||
#include "parser/scansup.h"
|
||||
#include "mb/pg_wchar.h"
|
||||
|
||||
|
Reference in New Issue
Block a user