Ah, I found what the actual problem is: we have sprinkled a few dependencies on "...-recurse" throught the tree, but the patch I posted yesterday changes the manufactured target as "-recursive", as it was prior to 1bd201214965; so essentially these manually added dependencies all became silent no-ops.
With this version I keep the target name as -recurse, and at least the ecpg<->libpq problem is no more AFAICT. -- Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/
>From 90a874bdf0e6f56d9c4ac1370d1765285db57e6b Mon Sep 17 00:00:00 2001 From: Alvaro Herrera <alvhe...@alvh.no-ip.org> Date: Mon, 25 Jul 2022 12:26:49 +0200 Subject: [PATCH v2] Try to undo 1bd201214965 --- src/Makefile.global.in | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/Makefile.global.in b/src/Makefile.global.in index 14fdd4ef7b..26ecfb2087 100644 --- a/src/Makefile.global.in +++ b/src/Makefile.global.in @@ -882,19 +882,14 @@ endif # using $(eval). It will set up a target so that it recurses into a # given subdirectory. For the tree-wide all/install/check/installcheck cases, # ensure we do our one-time tasks before recursing (see targets above). -# Note that to avoid a nasty bug in make 3.80, -# this function was written to not use any complicated constructs (like -# multiple targets on a line) and also not contain any lines that expand -# to more than about 200 bytes. This is why we make it apply to just one -# subdirectory at a time, rather than to a list of subdirectories. # $1: target name, e.g., all # $2: subdir name # $3: target to run in subdir, usually same as $1 define _create_recursive_target -.PHONY: $(1)-$(2)-recurse -$(1): $(1)-$(2)-recurse -$(1)-$(2)-recurse: $(if $(filter all install check installcheck, $(3)), submake-generated-headers) $(if $(filter check, $(3)), temp-install) - $$(MAKE) -C $(2) $(3) +.PHONY: $(patsubst %,$(1)-%-recurse,$(2)) +$(1): $(patsubst %,$(1)-%-recurse,$(2)) +$(2:%=$(1)-%-recurse): + $$(MAKE) -C $$(patsubst $(1)-%-recurse,%,$$@) $(3) endef # Note that the use of $$ on the last line above is important; we want # $(MAKE) to be evaluated when the rule is run, not when the $(eval) is run @@ -905,7 +900,7 @@ endef # $1: targets to make recursive (defaults to list of standard targets) # $2: list of subdirs (defaults to SUBDIRS variable) # $3: target to run in subdir (defaults to current element of $1) -recurse = $(foreach target,$(if $1,$1,$(standard_targets)),$(foreach subdir,$(if $2,$2,$(SUBDIRS)),$(eval $(call _create_recursive_target,$(target),$(subdir),$(if $3,$3,$(target)))))) +recurse = $(foreach target,$(if $1,$1,$(standard_targets)),$(eval $(call _create_recursive_target,$(target),$(if $2,$2,$(SUBDIRS)),$(if $3,$3,$(target))))) # If a makefile's list of SUBDIRS varies depending on configuration, then # any subdirectories excluded from SUBDIRS should instead be added to -- 2.30.2