[csw-devel] [PATCH] mGAR v2: A bugfix for EXPANDVARS
maciej at opencsw.org
maciej at opencsw.org
Sun Jan 9 07:57:18 CET 2011
From: Maciej Blizinski <maciej at opencsw.org>
The 'g' parameter was missing, and only one instance of a variable was
expanded per line. This patch adds 'g' to the perl invocation which expands
variables.
---
gar/v2/gar.mk | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/gar/v2/gar.mk b/gar/v2/gar.mk
index 4a3eee4..02b14f1 100644
--- a/gar/v2/gar.mk
+++ b/gar/v2/gar.mk
@@ -444,7 +444,7 @@ extract-p:
_var_definitions = $(foreach VAR,$(shell perl -ne 'print "$$1 " if( /@([^@]+)@/ )' <$1),$(VAR)=$($(VAR)))
expandvars-%:
- $(call _var_definitions,$(WORKDIR)/$*) perl -i-unexpanded -npe 's/@([^@]+)@/$$ENV{$$1}/e' $(WORKDIR)/$*
+ $(call _var_definitions,$(WORKDIR)/$*) perl -i-unexpanded -npe 's/@([^@]+)@/$$ENV{$$1}/eg' $(WORKDIR)/$*
@$(MAKECOOKIE)
--
1.7.1
More information about the devel
mailing list