From ca5910d42349d3a827d9b5f9b6f4fab4c87251b2 Mon Sep 17 00:00:00 2001 From: Jan Lindemann Date: Wed, 17 Dec 2025 12:15:30 +0100 Subject: [PATCH] tmpl.mk: Re-add because it's useful Templates (i.e. text files ending as .tmpl) are not part of jw-pkg anylonger, but controlling the way they are installed is beneficial to other packages, so add tmpl.mk back. That said, the variable names will need some tweaking to avoid collisions. Postponed. Signed-off-by: Jan Lindemann --- make/tmpl.mk | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 make/tmpl.mk diff --git a/make/tmpl.mk b/make/tmpl.mk new file mode 100644 index 00000000..425e3da8 --- /dev/null +++ b/make/tmpl.mk @@ -0,0 +1,22 @@ +include $(JWBDIR)/make/defs.mk + +# -- TMPL +INSTALLATION_FILE_TYPES += TMPL +BUILD_TMPLDIR = $(TOPDIR)/tmpl +LOCAL_TMPL += $(filter-out $(DONT_INSTALL),$(wildcard *.tmpl)) +ifndef TMPL_SUBDIR + TMPL_SUBDIR := $(shell $(PWD) | $(SED) '/.*\/tmpl\(\/\|$$\)/!d; s%.*/tmpl\(/\|$$\)%%') +endif +ifeq ($(TMPL_SUBDIR),) + INSTALL_TMPLDIR = $(PROJECT_TMPLDIR) +else + INSTALL_TMPLDIR = $(PROJECT_TMPLDIR)/$(TMPL_SUBDIR) +endif +INSTALLED_TMPL += $(addprefix $(INSTALL_TMPLDIR)/,$(LOCAL_TMPL)) + +include $(JWBDIR)/make/rules.mk + +all: +install: install_TMPL +clean: textclean localclean doneclean +test: