Skip Menu |

This queue is for tickets about the Slay-Makefile CPAN distribution.

Report information
The Basics
Id: 30428
Status: resolved
Worked: 20 min
Priority: 0/
Queue: Slay-Makefile

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.10
Fixed in: 0.12



Subject: Assigning variables with trailing backslash
It seems that backslashes may cause problems when running slaymake: $ slaymake FOO='bla\' 1: Can't find string terminator "]" anywhere before EOF at (eval 13) line 3. at ... This is only a problem for trailing backslashes. The attached patch should fix the problem. Regards, Slaven
Subject: Slaymake-backslash.patch
# # # To apply this patch: # STEP 1: Chdir to the source directory. # STEP 2: Run the 'applypatch' program with this patch file as input. # # If you do not have 'applypatch', it is part of the 'makepatch' package # that you can fetch from the Comprehensive Perl Archive Network: # http://www.perl.com/CPAN/authors/Johan_Vromans/makepatch-x.y.tar.gz # In the above URL, 'x' should be 2 or higher. # # To apply this patch without the use of 'applypatch': # STEP 1: Chdir to the source directory. # STEP 2: Run the 'patch' program with this file as input. # #### End of Preamble #### #### Patch data follows #### diff -up '../../build/Slay-Makefile-0.10-Ra6ayR/slaymake' 'slaymake' Index: ./slaymake --- ./slaymake Mon Sep 17 23:21:14 2007 +++ ./slaymake Fri Nov 2 12:59:20 2007 @@ -71,11 +71,14 @@ sub main { my %options; $options{debug} = 1 if $opt{d}; my $sm = Slay::Makefile->new(\%options); - $sm->parse_string(<<EOS) if %assigns; + if (%assigns) { + s{\\}{\\\\}g for values %assigns; + $sm->parse_string(<<EOS); { use vars qw(@{[map "\$$_", keys %assigns]}); @{[map "\$$_ = q[$assigns{$_}];\n", keys %assigns]}} EOS + } my $errs; if ($opt{e}) { $errs = $sm->parse_string(<<EOS) ; #### End of Patch data #### #### ApplyPatch data follows #### # Data version : 1.0 # Date generated : Fri Nov 2 13:02:13 2007 # Generated by : makepatch 2.00_12* # Recurse directories : Yes # Excluded files : (\A|/).*\~\Z # (\A|/).*\.a\Z # (\A|/).*\.bak\Z # (\A|/).*\.BAK\Z # (\A|/).*\.elc\Z # (\A|/).*\.exe\Z # (\A|/).*\.gz\Z # (\A|/).*\.ln\Z # (\A|/).*\.o\Z # (\A|/).*\.obj\Z # (\A|/).*\.olb\Z # (\A|/).*\.old\Z # (\A|/).*\.orig\Z # (\A|/).*\.rej\Z # (\A|/).*\.so\Z # (\A|/).*\.Z\Z # (\A|/)\.del\-.*\Z # (\A|/)\.make\.state\Z # (\A|/)\.nse_depinfo\Z # (\A|/)core\Z # (\A|/)tags\Z # (\A|/)TAGS\Z # p 'slaymake' 2865 1194004760 0100755 #### End of ApplyPatch data #### #### End of Patch kit [created: Fri Nov 2 13:02:13 2007] #### #### Patch checksum: 54 1864 50022 #### #### Checksum: 72 2488 36007 ####