From d0637dd93acbc312178e9f9f90bd957c6c9b6522 Mon Sep 17 00:00:00 2001 From: Wildan M Date: Sun, 26 Jul 2026 15:45:35 +0700 Subject: [PATCH] repo: Do not recurse deps at change rule when REPO_BINARY is set --- mk/config.mk | 2 +- mk/repo.mk | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/mk/config.mk b/mk/config.mk index 39202b416..2267e5090 100644 --- a/mk/config.mk +++ b/mk/config.mk @@ -15,7 +15,7 @@ PREFIX_BINARY?=1 ## Even more experimental, add -Zbuild-std to cookbook.toml to allow compilation to Tier 3 targets PREFIX_USE_UPSTREAM_RUST_COMPILER?=0 ## Enable to use binary packages (much faster) -REPO_BINARY?=0 +REPO_BINARY?= ## Name of the configuration to include in the image name e.g. desktop or server CONFIG_NAME?=desktop ## Build appstream data for repo diff --git a/mk/repo.mk b/mk/repo.mk index f9e9e8723..f31def80e 100644 --- a/mk/repo.mk +++ b/mk/repo.mk @@ -269,17 +269,27 @@ ucri.%: $(FSTOOLS_TAG) FORCE bc.%: $(FSTOOLS_TAG) FORCE ifeq ($(PODMAN_BUILD),1) $(PODMAN_RUN) make $@ +else +ifeq ($(REPO_BINARY),0) +# if explicitly set REPO_BINARY=0 (as opposed to leave it empty), this prevent dependencies to update + $(REPO_BIN) change-rule-local --set-rule=binary $(foreach f,$(subst $(comma), ,$*),$(f)) else $(REPO_BIN) change-rule --set-rule=binary $(foreach f,$(subst $(comma), ,$*),$(f)) --with-package-deps endif +endif # Set recipe rule to "source" then invoke clean sc.%: $(FSTOOLS_TAG) FORCE ifeq ($(PODMAN_BUILD),1) $(PODMAN_RUN) make $@ +else +ifeq ($(REPO_BINARY),1) +# if explicitly set REPO_BINARY=1, this prevent dependencies to update + $(REPO_BIN) change-rule-local --set-rule=source $(foreach f,$(subst $(comma), ,$*),$(f)) else $(REPO_BIN) change-rule --set-rule=source $(foreach f,$(subst $(comma), ,$*),$(f)) --with-package-deps endif +endif # Set specific recipe rule to "local" then invoke clean lc.%: $(FSTOOLS_TAG) FORCE