From 2728d489673f1d97a43e4f8d888b3591c233cfb7 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Tue, 6 Sep 2016 14:42:55 -0400 Subject: (systemd) build-aux: gitfiles --- build-aux/Makefile.once.head/00-quote.mk | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'build-aux/Makefile.once.head/00-quote.mk') diff --git a/build-aux/Makefile.once.head/00-quote.mk b/build-aux/Makefile.once.head/00-quote.mk index 23be614..17f6307 100644 --- a/build-aux/Makefile.once.head/00-quote.mk +++ b/build-aux/Makefile.once.head/00-quote.mk @@ -15,7 +15,13 @@ mod.quote.description = Macros to quote tricky strings -quote.pattern = $(subst %,\%,$(subst \,\\,$1)) +_quote.backslash = $(if $1,$(call _quote.backslash,$(wordlist 2,$(words $1),$1),$(subst $(firstword $1),\$(firstword $1),$2)),$2) + +quote.var = $(subst $(at.nl),\$(at.nl),$(subst $$,$$$$,$1)) +quote.pattern = $(call _quote.backslash, \ % ,$1) +quote.ere = $(call _quote.backslash, \ ^ . [ $$ ( ) | * + ? { ,$1) +quote.bre = $(call _quote.backslash, \ ^ . [ $$ * ,$1) + quote.shell-each = $(foreach _quote.tmp,$1,$(call quote.shell,$(_mod.tmp))) # I put this as the last line in the file because it confuses Emacs syntax -- cgit v1.2.3