Merge branch 'master' into core-updates
[jackhill/guix/guix.git] / gnu / packages / patches / automake-regexp-syntax.patch
1 From <https://lists.gnu.org/archive/html/automake-patches/2015-07/msg00000.html>.
2 See also <http://bugs.gnu.org/22372>.
3
4 From 34163794a58b5bd91c5d6bd9adf5437571c7a479 Mon Sep 17 00:00:00 2001
5 From: Pavel Raiskup <praiskup@redhat.com>
6 Date: Tue, 7 Jul 2015 10:54:24 +0200
7 Subject: [PATCH] bin/automake: escape '{' in regexp pattern
8
9 Based on perlre(1) documentation:
10 .. in Perl v5.26, literal uses of a curly bracket will be required
11 to be escaped, say by preceding them with a backslash ("\{" ) or
12 enclosing them within square brackets ("[{]") ..
13
14 References:
15 https://bugzilla.redhat.com/1239379
16
17 * bin/automake.in (substitute_ac_subst_variables): Escape the
18 occurrence of '{' character.
19 ---
20 bin/automake.in | 2 +-
21 1 file changed, 1 insertion(+), 1 deletion(-)
22
23 diff --git a/bin/automake.in b/bin/automake.in
24 index 0c29184..c294ced 100644
25 --- a/bin/automake.in
26 +++ b/bin/automake.in
27 @@ -3898,7 +3898,7 @@ sub substitute_ac_subst_variables_worker
28 sub substitute_ac_subst_variables
29 {
30 my ($text) = @_;
31 - $text =~ s/\${([^ \t=:+{}]+)}/substitute_ac_subst_variables_worker ($1)/ge;
32 + $text =~ s/\$\{([^ \t=:+{}]+)}/substitute_ac_subst_variables_worker ($1)/ge;
33 return $text;
34 }