Commit b58233c7 authored by Peter Eisentraut's avatar Peter Eisentraut

Fix PGXS vpath build when PostgreSQL is built with vpath

PGXS computes srcdir from VPATH, PostgreSQL proper computes VPATH from
srcdir, and doing both results in an error from make.  Conditionalize so
only one of these takes effect.
parent e4b5a070
...@@ -40,6 +40,8 @@ VERSION = @PACKAGE_VERSION@ ...@@ -40,6 +40,8 @@ VERSION = @PACKAGE_VERSION@
MAJORVERSION = @PG_MAJORVERSION@ MAJORVERSION = @PG_MAJORVERSION@
# Support for VPATH builds # Support for VPATH builds
# (PGXS VPATH support is handled separately in pgxs.mk)
ifndef PGXS
vpath_build = @vpath_build@ vpath_build = @vpath_build@
abs_top_srcdir = @abs_top_srcdir@ abs_top_srcdir = @abs_top_srcdir@
...@@ -51,6 +53,7 @@ top_srcdir = $(abs_top_srcdir) ...@@ -51,6 +53,7 @@ top_srcdir = $(abs_top_srcdir)
srcdir = $(top_srcdir)/$(subdir) srcdir = $(top_srcdir)/$(subdir)
VPATH = $(srcdir) VPATH = $(srcdir)
endif endif
endif # not PGXS
vpathsearch = `for f in $(addsuffix /$(1),$(subst :, ,. $(VPATH))); do test -r $$f && echo $$f && break; done` vpathsearch = `for f in $(addsuffix /$(1),$(subst :, ,. $(VPATH))); do test -r $$f && echo $$f && break; done`
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment