mirror of
https://github.com/postgres/postgres.git
synced 2025-07-15 19:21:59 +03:00
Arrange to compile flex output files as inclusions into other files
(usually bison output files), not as standalone files. This hack works around flex's insistence on including <stdio.h> before we are able to include postgres.h; postgres.h will already be read before the compiler starts to read the flex output file. Needed for largefile support on some platforms.
This commit is contained in:
@ -2,7 +2,7 @@
|
||||
#
|
||||
# Makefile for parser
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/src/backend/parser/Makefile,v 1.37 2002/04/20 21:56:14 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/src/backend/parser/Makefile,v 1.38 2002/11/01 22:52:33 tgl Exp $
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
@ -10,9 +10,11 @@ subdir = src/backend/parser
|
||||
top_builddir = ../../..
|
||||
include $(top_builddir)/src/Makefile.global
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
|
||||
OBJS= analyze.o gram.o keywords.o parser.o parse_agg.o parse_clause.o \
|
||||
parse_expr.o parse_func.o parse_node.o parse_oper.o parse_relation.o \
|
||||
parse_type.o parse_coerce.o parse_target.o scan.o scansup.o
|
||||
parse_type.o parse_coerce.o parse_target.o scansup.o
|
||||
|
||||
FLEXFLAGS = -CF
|
||||
|
||||
@ -23,6 +25,10 @@ SUBSYS.o: $(OBJS)
|
||||
$(LD) $(LDREL) $(LDOUT) $@ $^
|
||||
|
||||
|
||||
# scan is compiled as part of gram
|
||||
gram.o: $(srcdir)/scan.c
|
||||
|
||||
|
||||
# There is no correct way to write a rule that generates two files.
|
||||
# Rules with two targets don't have that meaning, they are merely
|
||||
# shorthand for two otherwise separate rules. To be safe for parallel
|
||||
@ -52,7 +58,7 @@ endif
|
||||
|
||||
# Force these dependencies to be known even without dependency info built:
|
||||
|
||||
keywords.o parse_clause.o parse_expr.o parser.o scan.o: $(srcdir)/parse.h
|
||||
keywords.o parse_clause.o parse_expr.o parser.o gram.o: $(srcdir)/parse.h
|
||||
|
||||
|
||||
# gram.c, parse.h, and scan.c are in the distribution tarball, so they
|
||||
|
@ -11,7 +11,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.371 2002/10/31 02:31:00 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 2.372 2002/11/01 22:52:33 tgl Exp $
|
||||
*
|
||||
* HISTORY
|
||||
* AUTHOR DATE MAJOR EVENT
|
||||
@ -7777,3 +7777,5 @@ doNegateFloat(Value *v)
|
||||
v->val.str = newval;
|
||||
}
|
||||
}
|
||||
|
||||
#include "scan.c"
|
||||
|
Reference in New Issue
Block a user