This is an automated email from the git hooks/post-receive script. guillem pushed a commit to branch main in repository dpkg.
View the commit online: https://git.dpkg.org/cgit/dpkg/dpkg.git/commit/?id=574081691a80a4d3d6e28caf249397fcb6ae37e1 commit 574081691a80a4d3d6e28caf249397fcb6ae37e1 Author: Nicolas Boulenguez <[email protected]> AuthorDate: Fri Jul 19 13:20:06 2024 +0200 scripts/mk: Ensure dpkg_datadir is computed once dpkg_datadir ?= $(dir $(lastword $(MAKEFILE_LIST))) is equivalent to ifndef dpkg_datadir dpkg_datadir = $(..) endif $(..) is computed each time dpkg_datadir is expanded, so the result will be wrong if MAKEFILE_LIST has grown meanwhile. Assign with := so that the value is computed and never expanded again. Signed-off-by: Guillem Jover <[email protected]> --- scripts/mk/buildtools.mk | 4 +++- scripts/mk/vendor.mk | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/scripts/mk/buildtools.mk b/scripts/mk/buildtools.mk index 1f63beede..def15c103 100644 --- a/scripts/mk/buildtools.mk +++ b/scripts/mk/buildtools.mk @@ -28,7 +28,9 @@ ifndef dpkg_buildtools_mk_included dpkg_buildtools_mk_included = yes -dpkg_datadir ?= $(dir $(lastword $(MAKEFILE_LIST))) +ifndef dpkg_datadir + dpkg_datadir := $(dir $(lastword $(MAKEFILE_LIST))) +endif include $(dpkg_datadir)/architecture.mk # We set the TOOL_FOR_BUILD variables to the specified value, and the TOOL diff --git a/scripts/mk/vendor.mk b/scripts/mk/vendor.mk index 43898d956..d257eddcb 100644 --- a/scripts/mk/vendor.mk +++ b/scripts/mk/vendor.mk @@ -36,7 +36,9 @@ ifndef dpkg_vendor_mk_included dpkg_vendor_mk_included = yes -dpkg_datadir ?= $(dir $(lastword $(MAKEFILE_LIST))) +ifndef dpkg_datadir + dpkg_datadir := $(dir $(lastword $(MAKEFILE_LIST))) +endif include $(dpkg_datadir)/buildapi.mk dpkg_lazy_eval ?= $(eval $(1) = $(2)$$($(1))) -- Dpkg.Org's dpkg

