1996-10-27 10:55:05 +01:00
|
|
|
#-------------------------------------------------------------------------
|
|
|
|
#
|
2000-07-19 18:30:27 +02:00
|
|
|
# Makefile for the bootstrap module
|
1996-10-27 10:55:05 +01:00
|
|
|
#
|
2008-02-19 11:30:09 +01:00
|
|
|
# $PostgreSQL: pgsql/src/backend/bootstrap/Makefile,v 1.36 2008/02/19 10:30:07 petere Exp $
|
1996-10-27 10:55:05 +01:00
|
|
|
#
|
|
|
|
#-------------------------------------------------------------------------
|
|
|
|
|
2000-07-19 18:30:27 +02:00
|
|
|
subdir = src/backend/bootstrap
|
|
|
|
top_builddir = ../../..
|
|
|
|
include $(top_builddir)/src/Makefile.global
|
1997-04-15 19:24:26 +02:00
|
|
|
|
2002-01-09 01:06:42 +01:00
|
|
|
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
|
|
|
|
2002-11-01 23:52:34 +01:00
|
|
|
OBJS= bootparse.o bootstrap.o
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2008-02-19 11:30:09 +01:00
|
|
|
include $(top_srcdir)/src/backend/common.mk
|
2000-07-19 18:30:27 +02:00
|
|
|
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2002-11-01 23:52:34 +01:00
|
|
|
# bootscanner is compiled as part of bootparse
|
|
|
|
bootparse.o: $(srcdir)/bootscanner.c
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2006-03-07 02:03:12 +01:00
|
|
|
# See notes in src/backend/parser/Makefile about the following two rules
|
2000-07-19 18:30:27 +02:00
|
|
|
|
2001-11-16 17:32:33 +01:00
|
|
|
$(srcdir)/bootparse.c: $(srcdir)/bootstrap_tokens.h ;
|
|
|
|
|
2006-03-07 02:03:12 +01:00
|
|
|
$(srcdir)/bootstrap_tokens.h: bootparse.y
|
2001-02-10 23:31:42 +01:00
|
|
|
ifdef YACC
|
2000-06-07 18:27:00 +02:00
|
|
|
$(YACC) -d $(YFLAGS) $<
|
2006-03-07 02:03:12 +01:00
|
|
|
mv -f y.tab.c $(srcdir)/bootparse.c
|
|
|
|
mv -f y.tab.h $(srcdir)/bootstrap_tokens.h
|
2001-02-10 23:31:42 +01:00
|
|
|
else
|
|
|
|
@$(missing) bison $< $@
|
|
|
|
endif
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2006-03-07 02:03:12 +01:00
|
|
|
$(srcdir)/bootscanner.c: bootscanner.l
|
2000-08-28 13:53:23 +02:00
|
|
|
ifdef FLEX
|
2006-03-07 02:03:12 +01:00
|
|
|
$(FLEX) $(FLEXFLAGS) -o'$@' $<
|
2000-08-28 13:53:23 +02:00
|
|
|
else
|
|
|
|
@$(missing) flex $< $@
|
|
|
|
endif
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2006-03-07 02:03:12 +01:00
|
|
|
# Force these dependencies to be known even without dependency info built:
|
|
|
|
bootstrap.o bootparse.o: $(srcdir)/bootstrap_tokens.h
|
|
|
|
|
|
|
|
|
|
|
|
# bootparse.c, bootstrap_tokens.h, and bootscanner.c are in the distribution
|
|
|
|
# tarball, so they are not cleaned here.
|
1996-10-27 10:55:05 +01:00
|
|
|
clean:
|
|
|
|
# And the garbage that might have been left behind by partial build:
|
2000-07-19 18:30:27 +02:00
|
|
|
@rm -f y.tab.h y.tab.c y.output lex.yy.c
|