Remove make function vpathsearch
authorPeter Eisentraut <peter@eisentraut.org>
Mon, 29 Jan 2024 06:22:43 +0000 (07:22 +0100)
committerPeter Eisentraut <peter@eisentraut.org>
Mon, 29 Jan 2024 06:24:59 +0000 (07:24 +0100)
This function served to support having prebuilt files in the source
tree for vpath builds.  This is no longer possible (since
721856ff24b); all built files are now always in the build tree.  The
invocations of this function are no longer required.

doc/src/sgml/Makefile
src/Makefile.global.in
src/backend/catalog/Makefile

index 725fec59e78bac38939fb7c58d914a037841e9d7..9c9bbfe375d8412cb6ad21d99a561ee027baa39a 100644 (file)
@@ -215,7 +215,7 @@ uninstall:
 ## Install html
 
 install-html: html installdirs
-       cp -R $(call vpathsearch,html) '$(DESTDIR)$(htmldir)'
+       cp -R html '$(DESTDIR)$(htmldir)'
 
 
 ## Install man
@@ -230,7 +230,7 @@ sqlmansectnum = $(shell expr X'$(sqlmansect)' : X'\([0-9]\)')
 #
 ifeq ($(sqlmansectnum),7)
 install-man:
-       cp -R $(foreach dir,man1 man3 man7,$(call vpathsearch,$(dir))) '$(DESTDIR)$(mandir)'
+       cp -R man1 man3 man7 '$(DESTDIR)$(mandir)'
 
 else # sqlmansectnum != 7
 fix_sqlmansectnum = sed -e '/^\.TH/s/"7"/"$(sqlmansect)"/' \
@@ -241,9 +241,9 @@ man: fixed-man-stamp
 
 fixed-man-stamp: man-stamp
        @$(MKDIR_P) $(addprefix fixedman/,man1 man3 man$(sqlmansectnum))
-       for file in $(call vpathsearch,man1)/*.1; do $(fix_sqlmansectnum) $$file >fixedman/man1/`basename $$file` || exit; done
-       for file in $(call vpathsearch,man3)/*.3; do $(fix_sqlmansectnum) $$file >fixedman/man3/`basename $$file` || exit; done
-       for file in $(call vpathsearch,man7)/*.7; do $(fix_sqlmansectnum) $$file >fixedman/man$(sqlmansectnum)/`basename $$file | sed s/\.7$$/.$(sqlmansect)/` || exit; done
+       for file in man1/*.1; do $(fix_sqlmansectnum) $$file >fixedman/man1/`basename $$file` || exit; done
+       for file in man3/*.3; do $(fix_sqlmansectnum) $$file >fixedman/man3/`basename $$file` || exit; done
+       for file in man7/*.7; do $(fix_sqlmansectnum) $$file >fixedman/man$(sqlmansectnum)/`basename $$file | sed s/\.7$$/.$(sqlmansect)/` || exit; done
 
 install-man:
        cp -R $(foreach dir,man1 man3 man$(sqlmansectnum),fixedman/$(dir)) '$(DESTDIR)$(mandir)'
index 6f7de20527c04f15cba18acf29d826e7d29e3cf5..8b3f8c24e08e8a7527f3735686b515403efac521 100644 (file)
@@ -76,8 +76,6 @@ VPATH = $(srcdir)
 endif
 endif # not PGXS
 
-vpathsearch = `for f in $(addsuffix /$(1),$(subst :, ,. $(VPATH))); do test -r $$f && echo $$f && break; done`
-
 
 ##########################################################################
 #
index 352ba6d3e2eb85a7a5c710ed5322e6ab8ea5c7c1..196ecafc9099de9618844b8e6aff71da3788c684 100644 (file)
@@ -183,8 +183,8 @@ $(top_builddir)/src/include/catalog/header-stamp: bki-stamp
 # Note: installation of generated headers is handled elsewhere
 .PHONY: install-data
 install-data: bki-stamp installdirs
-       $(INSTALL_DATA) $(call vpathsearch,postgres.bki) '$(DESTDIR)$(datadir)/postgres.bki'
-       $(INSTALL_DATA) $(call vpathsearch,system_constraints.sql) '$(DESTDIR)$(datadir)/system_constraints.sql'
+       $(INSTALL_DATA) postgres.bki '$(DESTDIR)$(datadir)/postgres.bki'
+       $(INSTALL_DATA) system_constraints.sql '$(DESTDIR)$(datadir)/system_constraints.sql'
        $(INSTALL_DATA) $(srcdir)/system_functions.sql '$(DESTDIR)$(datadir)/system_functions.sql'
        $(INSTALL_DATA) $(srcdir)/system_views.sql '$(DESTDIR)$(datadir)/system_views.sql'
        $(INSTALL_DATA) $(srcdir)/information_schema.sql '$(DESTDIR)$(datadir)/information_schema.sql'