1996-10-27 10:55:05 +01:00
|
|
|
#-------------------------------------------------------------------------
|
|
|
|
#
|
|
|
|
# Makefile--
|
|
|
|
# Makefile for utils
|
|
|
|
#
|
|
|
|
# IDENTIFICATION
|
2000-06-09 04:38:36 +02:00
|
|
|
# $Header: /cvsroot/pgsql/src/backend/utils/Makefile,v 1.14 2000/06/09 02:38:36 tgl Exp $
|
1996-10-27 10:55:05 +01:00
|
|
|
#
|
|
|
|
#-------------------------------------------------------------------------
|
|
|
|
|
1996-11-03 10:28:31 +01:00
|
|
|
SRCDIR = ../..
|
2000-05-28 19:56:29 +02:00
|
|
|
include $(SRCDIR)/Makefile.global
|
1996-11-03 10:28:31 +01:00
|
|
|
|
1996-11-02 03:03:50 +01:00
|
|
|
all: submake SUBSYS.o
|
1996-10-27 10:55:05 +01:00
|
|
|
|
1996-11-02 03:03:50 +01:00
|
|
|
OBJS = fmgrtab.o adt/SUBSYS.o cache/SUBSYS.o error/SUBSYS.o \
|
|
|
|
fmgr/SUBSYS.o hash/SUBSYS.o init/SUBSYS.o misc/SUBSYS.o mmgr/SUBSYS.o \
|
|
|
|
sort/SUBSYS.o time/SUBSYS.o
|
|
|
|
|
1998-04-06 02:32:26 +02:00
|
|
|
DIRS = adt cache error fmgr hash init misc mmgr sort time
|
|
|
|
|
1998-07-26 06:31:41 +02:00
|
|
|
ifdef MULTIBYTE
|
1998-07-24 05:32:46 +02:00
|
|
|
OBJS += mb/SUBSYS.o
|
|
|
|
DIRS += mb
|
|
|
|
endif
|
|
|
|
|
1996-11-02 03:03:50 +01:00
|
|
|
SUBSYS.o: $(OBJS)
|
1999-12-13 23:35:27 +01:00
|
|
|
$(LD) $(LDREL) $(LDOUT) SUBSYS.o $(OBJS)
|
1996-11-02 03:03:50 +01:00
|
|
|
|
2000-06-09 04:38:36 +02:00
|
|
|
.PHONY: submake clean dep depend
|
|
|
|
|
1996-11-02 03:03:50 +01:00
|
|
|
submake:
|
1998-04-06 02:32:26 +02:00
|
|
|
for i in $(DIRS); do $(MAKE) -C $$i SUBSYS.o; done
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2000-06-07 18:27:00 +02:00
|
|
|
# Gen_fmgrtab.sh will not change the timestamp of its output files
|
|
|
|
# if they already exist and would not be changed. This is to avoid
|
|
|
|
# unnecessary recompilations. In order to avoid re-running it all
|
|
|
|
# the time we update a stamp file instead. (Idea stolen from
|
|
|
|
# autoconf and autoheader.)
|
|
|
|
|
|
|
|
fmgroids.h fmgrtab.c: fmgrstamp-h
|
2000-06-09 04:38:36 +02:00
|
|
|
|
2000-06-07 18:27:00 +02:00
|
|
|
fmgrstamp-h: Gen_fmgrtab.sh $(SRCDIR)/include/catalog/pg_proc.h
|
2000-05-28 19:56:29 +02:00
|
|
|
$(SHELL) $(SHOPTS) Gen_fmgrtab.sh $(SRCDIR)/include/catalog/pg_proc.h
|
2000-06-09 04:38:36 +02:00
|
|
|
date > fmgrstamp-h
|
|
|
|
|
|
|
|
# don't clean fmgroids.h and fmgrtab.c, but do clean fmgrstamp-h
|
|
|
|
# (we don't really want to put that much trust in timestamps in
|
|
|
|
# distribution files and CVS pulls, so force at least one run of
|
|
|
|
# Gen_fmgrtab.sh after a make clean)
|
1996-10-27 10:55:05 +01:00
|
|
|
|
|
|
|
clean:
|
2000-06-09 04:38:36 +02:00
|
|
|
rm -f SUBSYS.o fmgrtab.o fmgrstamp-h
|
1998-04-06 02:32:26 +02:00
|
|
|
for i in $(DIRS); do $(MAKE) -C $$i clean; done
|
1996-10-27 10:55:05 +01:00
|
|
|
|
2000-05-28 19:56:29 +02:00
|
|
|
dep depend: fmgroids.h fmgrtab.c
|
1998-04-06 02:32:26 +02:00
|
|
|
for i in $(DIRS); do $(MAKE) -C $$i depend; done
|
1996-10-27 10:55:05 +01:00
|
|
|
|
|
|
|
ifeq (depend,$(wildcard depend))
|
|
|
|
include depend
|
|
|
|
endif
|