From 7f85a5f2d60c6c065c36850104c05b6a6e7f1e2d Mon Sep 17 00:00:00 2001 From: Jan Lindemann Date: Tue, 17 Feb 2026 17:37:03 +0100 Subject: [PATCH] projects+project.mk: Add file Multiple variables are redundantly defined both for a project and for the multiple-projects toplevel directory. Add a place to maintain them centrally, and add PGIT_SH as a first variable. Signed-off-by: Jan Lindemann --- make/projects+project.mk | 5 +++++ make/projects-dir-include.mk | 1 + make/projects-dir.mk | 1 - 3 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 make/projects+project.mk diff --git a/make/projects+project.mk b/make/projects+project.mk new file mode 100644 index 00000000..46c29242 --- /dev/null +++ b/make/projects+project.mk @@ -0,0 +1,5 @@ +# This file contains definitions useful to both Makefiles inside a project, and +# the Makefile inside the toplevel directory containing multiple projects (see +# projects-dir-minimal.mk / projects-dir.mk for details) + +PGIT_SH = /bin/bash $(JWB_SCRIPT_DIR)/pgit.sh diff --git a/make/projects-dir-include.mk b/make/projects-dir-include.mk index 4c3f3043..d7f5fe2c 100644 --- a/make/projects-dir-include.mk +++ b/make/projects-dir-include.mk @@ -1,3 +1,4 @@ all: +include $(JWBDIR)/make/projects+project.mk include $(JWBDIR)/make/projects-dir.mk diff --git a/make/projects-dir.mk b/make/projects-dir.mk index e0db55af..06436f6d 100644 --- a/make/projects-dir.mk +++ b/make/projects-dir.mk @@ -118,7 +118,6 @@ JW_PKG_PY_PROJECTS = $(JW_PKG_PY) projects JW_PKG_PY_BUILD = $(JW_PKG_PY_PROJECTS) build $(JW_PKG_PY_EXTRA_BUILD_OPTS) PKG_MANAGER ?= $(JW_PKG_PY) distro --interactive=$(INTERACTIVE) -PGIT_SH := /bin/bash $(JWB_SCRIPT_DIR)/pgit.sh ifneq ($(origin PROJECTS_DIR_REMOTE_BASE),undefined) PGIT_SH += --remote-base $(PROJECTS_DIR_REMOTE_BASE) endif