2 # PostgreSQL top level makefile
9 include $(top_builddir
)/src
/Makefile.global
15 @echo
"All of PostgreSQL successfully made. Ready to install."
21 @echo
"PostgreSQL installation complete."
23 installdirs uninstall:
34 # clean, distclean, etc should apply to contrib too, even though
35 # it's not built by default
41 # Garbage from autoconf:
42 @
rm -rf autom4te.cache
/
44 # Important: distclean `src' last, otherwise Makefile.global
45 # will be gone too soon.
46 distclean maintainer-clean
:
51 rm -f config.cache config.log config.status GNUmakefile
52 # Garbage from autoconf:
53 @
rm -rf autom4te.cache
/
57 check installcheck installcheck-parallel
:
58 $(MAKE
) -C src
/test $@
60 GNUmakefile
: GNUmakefile.in
$(top_builddir
)/config.status
64 ##########################################################################
66 distdir
= postgresql-
$(VERSION
)
68 garbage
= =* "#"* .
"#"* *~
* *.orig
*.rej core postgresql-
*
70 dist: $(distdir
).
tar.gz
71 ifeq ($(split-dist
), yes
)
72 dist: postgresql-base-
$(VERSION
).
tar.gz postgresql-docs-
$(VERSION
).
tar.gz postgresql-opt-
$(VERSION
).
tar.gz postgresql-test-
$(VERSION
).
tar.gz
77 $(distdir
).
tar: distdir
78 $(TAR
) chf
$@
$(distdir
)
81 src
/tools src
/tutorial \
82 $(addprefix src
/pl
/, plperl plpython tcl
)
84 docs_files
= doc
/postgres.
tar.gz doc
/src doc
/TODO.detail
86 postgresql-base-
$(VERSION
).
tar: distdir
87 $(TAR
) -c
$(addprefix --exclude
$(distdir
)/, $(docs_files
) $(opt_files
) src
/test) \
90 postgresql-docs-
$(VERSION
).
tar: distdir
91 $(TAR
) cf
$@
$(addprefix $(distdir
)/, $(docs_files
))
93 postgresql-opt-
$(VERSION
).
tar: distdir
94 $(TAR
) cf
$@
$(addprefix $(distdir
)/, $(opt_files
))
96 postgresql-test-
$(VERSION
).
tar: distdir
97 $(TAR
) cf
$@
$(distdir
)/src
/test
100 rm -rf
$(distdir
)* $(dummy
)
101 for x in
`cd $(top_srcdir) && find . -name CVS -prune -o -print`; do \
102 file
=`expr X$$x : 'X\./\(.*\)'`; \
103 if
test -d
"$(top_srcdir)/$$file" ; then \
104 mkdir
"$(distdir)/$$file" && chmod
777 "$(distdir)/$$file"; \
106 ln
"$(top_srcdir)/$$file" "$(distdir)/$$file" >/dev
/null
2>&1 \
107 || cp
"$(top_srcdir)/$$file" "$(distdir)/$$file"; \
110 $(MAKE
) -C
$(distdir
) distprep
111 $(MAKE
) -C
$(distdir
)/doc
/src
/sgml
/ HISTORY INSTALL regress_README
112 cp
$(distdir
)/doc
/src
/sgml
/HISTORY
$(distdir
)/
113 cp
$(distdir
)/doc
/src
/sgml
/INSTALL
$(distdir
)/
114 cp
$(distdir
)/doc
/src
/sgml
/regress_README
$(distdir
)/src
/test/regress
/README
115 $(MAKE
) -C
$(distdir
) distclean
116 rm -f
$(distdir
)/README.CVS
118 distcheck
: $(distdir
).
tar.gz
121 $(GZIP
) -d
-c
$< |
$(TAR
) xf
-
122 install_prefix
=`cd $(dummy) && pwd`; \
124 && .
/configure
--prefix="$$install_prefix"
125 $(MAKE
) -C
$(distdir
) -q distprep
126 $(MAKE
) -C
$(distdir
)
127 $(MAKE
) -C
$(distdir
) install
128 $(MAKE
) -C
$(distdir
) uninstall
129 @echo
"checking whether \`$(MAKE) uninstall' works"
130 test `find $(dummy) ! -type d | wc -l` -eq
0
131 $(MAKE
) -C
$(distdir
) dist
132 # Room for improvement: Check here whether this distribution tarball
133 # is sufficiently similar to the original one.
134 rm -rf
$(distdir
) $(dummy
)
135 @echo
"Distribution integrity checks out."
137 .PHONY
: dist distdir distcheck