summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2002-11-01 22:52:34 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2002-11-01 22:52:34 +0000
commitcab9437a43db6b233e2308aeb71a0b3bac600410 (patch)
tree280ba825388918ace298e05f4d306b9cf71847ae /contrib
parent1e970dcee821fbf6b1fa2aa64765ca762e0491f7 (diff)
downloadpostgresql-cab9437a43db6b233e2308aeb71a0b3bac600410.tar.gz
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.
Diffstat (limited to 'contrib')
-rw-r--r--contrib/cube/Makefile7
-rw-r--r--contrib/cube/cubeparse.y1
-rw-r--r--contrib/seg/Makefile7
-rw-r--r--contrib/seg/segparse.y2
-rw-r--r--contrib/tsearch/Makefile7
-rw-r--r--contrib/tsearch/query.c2
6 files changed, 19 insertions, 7 deletions
diff --git a/contrib/cube/Makefile b/contrib/cube/Makefile
index 1bf47b90e9..0cdb317fda 100644
--- a/contrib/cube/Makefile
+++ b/contrib/cube/Makefile
@@ -1,17 +1,20 @@
-# $Header: /cvsroot/pgsql/contrib/cube/Makefile,v 1.6 2001/11/16 16:32:33 petere Exp $
+# $Header: /cvsroot/pgsql/contrib/cube/Makefile,v 1.7 2002/11/01 22:52:33 tgl Exp $
subdir = contrib/cube
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
MODULE_big = cube
-OBJS= cube.o cubeparse.o cubescan.o buffer.o
+OBJS= cube.o cubeparse.o buffer.o
DATA_built = cube.sql
DOCS = README.cube
REGRESS = cube
+# cubescan is compiled as part of cubeparse
+cubeparse.o: cubescan.c
+
cubeparse.c: cubeparse.h ;
cubeparse.h: cubeparse.y
diff --git a/contrib/cube/cubeparse.y b/contrib/cube/cubeparse.y
index 7810d7f1e9..95bc016431 100644
--- a/contrib/cube/cubeparse.y
+++ b/contrib/cube/cubeparse.y
@@ -276,3 +276,4 @@ static NDBOX * write_point_as_box(char *str, int dim)
return(bp);
}
+#include "cubescan.c"
diff --git a/contrib/seg/Makefile b/contrib/seg/Makefile
index ac9b543d83..350e134798 100644
--- a/contrib/seg/Makefile
+++ b/contrib/seg/Makefile
@@ -1,16 +1,19 @@
-# $Header: /cvsroot/pgsql/contrib/seg/Makefile,v 1.6 2001/11/16 16:32:33 petere Exp $
+# $Header: /cvsroot/pgsql/contrib/seg/Makefile,v 1.7 2002/11/01 22:52:33 tgl Exp $
subdir = contrib/seg
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
MODULE_big = seg
-OBJS = seg.o segparse.o segscan.o buffer.o
+OBJS = seg.o segparse.o buffer.o
DATA_built = seg.sql
DOCS = README.seg
REGRESS = seg
+# segscan is compiled as part of segparse
+segparse.o: segscan.c
+
segparse.c: segparse.h ;
segparse.h: segparse.y
diff --git a/contrib/seg/segparse.y b/contrib/seg/segparse.y
index 1195198f58..9e18379bc8 100644
--- a/contrib/seg/segparse.y
+++ b/contrib/seg/segparse.y
@@ -179,4 +179,4 @@ int seg_yyerror ( char *msg ) {
return 0;
}
-
+#include "segscan.c"
diff --git a/contrib/tsearch/Makefile b/contrib/tsearch/Makefile
index 8241c261c0..ee6eeb1e84 100644
--- a/contrib/tsearch/Makefile
+++ b/contrib/tsearch/Makefile
@@ -1,16 +1,19 @@
-# $Header: /cvsroot/pgsql/contrib/tsearch/Attic/Makefile,v 1.1 2001/10/12 23:19:09 tgl Exp $
+# $Header: /cvsroot/pgsql/contrib/tsearch/Attic/Makefile,v 1.2 2002/11/01 22:52:33 tgl Exp $
subdir = contrib/tsearch
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
MODULE_big = tsearch
-OBJS = parser.o crc32.o morph.o txtidx.o query.o gistidx.o rewrite.o
+OBJS = crc32.o morph.o txtidx.o query.o gistidx.o rewrite.o
DATA_built = tsearch.sql
DOCS = README.tsearch
REGRESS = tsearch
+# parser is compiled as part of query
+query.o: parser.c
+
parser.c: parser.l
ifdef FLEX
$(FLEX) $(FLEXFLAGS) -8 -Ptsearch_yy -o'$@' $<
diff --git a/contrib/tsearch/query.c b/contrib/tsearch/query.c
index b69151c879..9d5e126c5b 100644
--- a/contrib/tsearch/query.c
+++ b/contrib/tsearch/query.c
@@ -805,3 +805,5 @@ querytree(PG_FUNCTION_ARGS)
PG_RETURN_POINTER(res);
}
+
+#include "parser.c"