summaryrefslogtreecommitdiff
path: root/src/backend/Makefile
diff options
context:
space:
mode:
authorPeter Eisentraut2000-10-20 21:04:27 +0000
committerPeter Eisentraut2000-10-20 21:04:27 +0000
commit805e431a3868ac71681316927403d1ba389e113b (patch)
treee20ff81ccb4be79cbd43e87cf76f33ee5fb1887d /src/backend/Makefile
parent039f3f1b051b189e7ccf0c28d86d415e693ee8d6 (diff)
Add support for VPATH builds, that is, building somewhere else than in the
source directory. This involves mostly makefiles using $(srcdir) when they might have used ".". (Regression tests don't work with this, yet.) Sort out usage of CPPFLAGS, CFLAGS (and CXXFLAGS). Add "override" keyword in most places, to preserve necessary flags even when the user overrode the flags.
Diffstat (limited to 'src/backend/Makefile')
-rw-r--r--src/backend/Makefile15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/backend/Makefile b/src/backend/Makefile
index 3b29f52307..07c18427bf 100644
--- a/src/backend/Makefile
+++ b/src/backend/Makefile
@@ -4,7 +4,7 @@
#
# Copyright (c) 1994, Regents of the University of California
#
-# $Header: /cvsroot/pgsql/src/backend/Makefile,v 1.66 2000/10/07 18:43:22 petere Exp $
+# $Header: /cvsroot/pgsql/src/backend/Makefile,v 1.67 2000/10/20 21:03:39 petere Exp $
#
#-------------------------------------------------------------------------
@@ -58,7 +58,7 @@ $(OBJS): $(DIRS:%=%-recursive)
.PHONY: $(DIRS:%=%-recursive)
# Update the commonly used headers before building the subdirectories
-$(DIRS:%=%-recursive): $(top_srcdir)/src/include/parser/parse.h $(top_builddir)/src/include/utils/fmgroids.h
+$(DIRS:%=%-recursive): $(top_builddir)/src/include/parser/parse.h $(top_builddir)/src/include/utils/fmgroids.h
$(MAKE) -C $(subst -recursive,,$@) all
@@ -98,8 +98,9 @@ utils/fmgroids.h: utils/Gen_fmgrtab.sh $(top_srcdir)/src/include/catalog/pg_proc
# up to date when we update the base file.
$(top_builddir)/src/include/parser/parse.h: $(srcdir)/parser/parse.h
- cd $(dir $@) && rm -f $(notdir $@) && \
- $(LN_S) ../../../$(subdir)/parser/parse.h .
+ prereqdir=`cd $(dir $<) && pwd` && \
+ cd $(dir $@) && rm -f $(notdir $@) && \
+ $(LN_S) $$prereqdir/$(notdir $<) .
$(top_builddir)/src/include/utils/fmgroids.h: utils/fmgroids.h
cd $(dir $@) && rm -f $(notdir $@) && \
@@ -123,9 +124,9 @@ ifeq ($(MAKE_DLL), true)
endif
endif
$(MAKE) -C catalog install-bki
- $(INSTALL_DATA) libpq/pg_hba.conf.sample $(DESTDIR)$(datadir)/pg_hba.conf.sample
- $(INSTALL_DATA) libpq/pg_ident.conf.sample $(DESTDIR)$(datadir)/pg_ident.conf.sample
- $(INSTALL_DATA) utils/misc/postgresql.conf.sample $(DESTDIR)$(datadir)/postgresql.conf.sample
+ $(INSTALL_DATA) $(srcdir)/libpq/pg_hba.conf.sample $(DESTDIR)$(datadir)/pg_hba.conf.sample
+ $(INSTALL_DATA) $(srcdir)/libpq/pg_ident.conf.sample $(DESTDIR)$(datadir)/pg_ident.conf.sample
+ $(INSTALL_DATA) $(srcdir)/utils/misc/postgresql.conf.sample $(DESTDIR)$(datadir)/postgresql.conf.sample
installdirs:
$(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(libdir) $(DESTDIR)$(datadir)