]> granicus.if.org Git - postgresql/blob - GNUmakefile.in
BufferAlloc() doesn't allocate write error buffers.
[postgresql] / GNUmakefile.in
1 #
2 # PostgreSQL top level makefile
3 #
4 # $Header: /cvsroot/pgsql/GNUmakefile.in,v 1.12 2000/09/21 20:17:41 petere Exp $
5 #
6
7 subdir =
8 top_builddir = .
9 include $(top_builddir)/src/Makefile.global
10
11 all:
12         $(MAKE) -C doc all
13         $(MAKE) -C src all
14         @echo "All of PostgreSQL successfully made. Ready to install."
15
16 install:
17         $(MAKE) -C doc install
18         $(MAKE) -C src install
19         @cat $(srcdir)/register.txt
20
21 installdirs uninstall clean distprep:
22         $(MAKE) -C doc $@
23         $(MAKE) -C src $@
24
25 # Important: distclean `doc' before `src', otherwise Makefile.global
26 # will be gone too soon.
27 distclean maintainer-clean:
28         -$(MAKE) -C doc $@
29         -$(MAKE) -C src $@
30         -rm -f config.cache config.log config.status GNUmakefile
31
32
33 GNUmakefile: GNUmakefile.in $(top_builddir)/config.status
34         CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status
35
36
37 ##########################################################################
38
39 distdir := postgresql-$(VERSION)
40 dummy   := =install=
41 garbage := =*  "#"*  ."#"*  *~*  *.orig  *.rej  core  postgresql-*
42
43 GZIP    := gzip
44 BZIP2   := bzip2
45
46 dist: $(distdir).tar.gz
47 ifeq ($(split-dist), yes)
48 dist: $(distdir).base.tar.gz $(distdir).docs.tar.gz $(distdir).support.tar.gz $(distdir).test.tar.gz
49 endif
50 dist:
51         -rm -rf $(distdir)
52
53 $(distdir).tar: distdir
54         $(TAR) chf $@ $(distdir)
55
56 $(distdir).base.tar: distdir
57         $(TAR) -c $(addprefix --exclude $(distdir)/, doc src/test src/interfaces src/bin) \
58           -f $@ $(distdir)
59
60 $(distdir).docs.tar: distdir
61         $(TAR) cf $@ $(distdir)/doc
62
63 $(distdir).support.tar: distdir
64         $(TAR) cf $@ $(distdir)/src/interfaces $(distdir)/src/bin
65
66 $(distdir).test.tar: distdir
67         $(TAR) cf $@ $(distdir)/src/test
68
69 %.gz: %
70         $(GZIP) -f --best $<
71
72 %.bz2: %
73         $(BZIP2) -f $<
74
75 distdir:
76         -rm -rf $(distdir)* $(dummy)
77         for x in `cd $(top_srcdir) && find . -name CVS -prune -o -print`; do \
78           file=`expr X$$x : 'X\./\(.*\)'`; \
79           if test -d "$(top_srcdir)/$$file" ; then \
80             mkdir "$(distdir)/$$file" && chmod 777 "$(distdir)/$$file"; \
81           else \
82             ln "$(top_srcdir)/$$file" "$(distdir)/$$file" >/dev/null 2>&1 \
83               || cp "$(top_srcdir)/$$file" "$(distdir)/$$file"; \
84           fi || exit; \
85         done
86         $(MAKE) -C $(distdir) distprep
87         $(MAKE) -C $(distdir) distclean
88
89 distcheck: $(distdir).tar.gz
90         -rm -rf $(dummy)
91         mkdir $(dummy)
92         gzip -d -c $< | $(TAR) xf -
93         install_prefix=`cd $(dummy) && pwd`; \
94         cd $(distdir) \
95         && ./configure --prefix="$$install_prefix"
96         $(MAKE) -C $(distdir) -q distprep
97         $(MAKE) -C $(distdir)
98         $(MAKE) -C $(distdir) install
99         $(MAKE) -C $(distdir) uninstall
100         @echo "checking whether \`$(MAKE) uninstall' works"
101         test `find $(dummy) -not -type d | wc -l` -eq 0
102         $(MAKE) -C $(distdir) dist
103 # Room for improvement: Check here whether this distribution tarball
104 # is sufficiently similar to the original one.
105         -rm -rf $(distdir) $(dummy)
106         @echo "Distribution integrity checks out."
107
108 .PHONY: dist distdir distcheck