Ticket #50771: 0001-Revert-perlasm-x86_64-xlate.pl-pass-pure-constants-v.patch

File 0001-Revert-perlasm-x86_64-xlate.pl-pass-pure-constants-v.patch, 1.3 KB (added by neverpanic (Clemens Lang), 9 years ago)
  • crypto/perlasm/x86_64-xlate.pl

    From 6f79f210c690c31bce632570bf703a2360af6827 Mon Sep 17 00:00:00 2001
    From: Clemens Lang <neverpanic@gmail.com>
    Date: Sun, 6 Mar 2016 21:28:56 +0100
    Subject: [PATCH 1/2] Revert "perlasm/x86_64-xlate.pl: pass pure constants
     verbatim."
    
    This reverts commit fd7dc201d3b9d43972de6a0e659f7ef6421c99cc.
    
    This commit causes build failures on OS X 10.6. For more details, see
      https://mta.openssl.org/pipermail/openssl-dev/2016-March/005605.html
    ---
     crypto/perlasm/x86_64-xlate.pl | 7 ++-----
     1 file changed, 2 insertions(+), 5 deletions(-)
    
    diff --git a/crypto/perlasm/x86_64-xlate.pl b/crypto/perlasm/x86_64-xlate.pl
    index 0a023fb..29f94b5 100755
    a b my %globals; 
    198198        if ($gas) {
    199199            # Solaris /usr/ccs/bin/as can't handle multiplications
    200200            # in $self->{value}
    201             my $value = $self->{value};
    202             $value =~ s/(?<![\w\$\.])(0x?[0-9a-f]+)/oct($1)/egi;
    203             if ($value =~ s/([0-9]+\s*[\*\/\%]\s*[0-9]+)/eval($1)/eg) {
    204                 $self->{value} = $value;
    205             }
     201            $self->{value} =~ s/(?<![\w\$\.])(0x?[0-9a-f]+)/oct($1)/egi;
     202            $self->{value} =~ s/([0-9]+\s*[\*\/\%]\s*[0-9]+)/eval($1)/eg;
    206203            sprintf "\$%s",$self->{value};
    207204        } else {
    208205            $self->{value} =~ s/(0b[0-1]+)/oct($1)/eig;