diff options
author | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-09-06 14:42:55 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-09-06 14:42:55 -0400 |
commit | 3fbf31965b37b0a5c91b0121aec12af066d7726c (patch) | |
tree | c9d5110843e1124ce53ba10870ce75d209b452a1 /build-aux/Makefile.once.head/00-quote.mk | |
parent | 4160043a0fac8b812905b7502ce34adf3af538f1 (diff) |
build-aux: gitfiles
Diffstat (limited to 'build-aux/Makefile.once.head/00-quote.mk')
-rw-r--r-- | build-aux/Makefile.once.head/00-quote.mk | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/build-aux/Makefile.once.head/00-quote.mk b/build-aux/Makefile.once.head/00-quote.mk index 23be6140d6..17f63077e6 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 |