Support uuencoded binutils.
[nethome.git] / bin / hammock
index c0c9137..66c50f6 100755 (executable)
@@ -208,9 +208,7 @@ for my $distro (@distrouse) {
     my($c)=@_;
 
     $c="export PATH=\"$path:\$PATH\"; $c" if $path;
-    $c="export MAKEFLAGS=\"-j\$[`getconf _NPROCESSORS_ONLN`*3/2]\"; $c"
-       # FIXME: The testsuite results from binutils.spec should be uuencoded.
-       if $component!~/^(?:fedora|rhel)binutils$/;
+    $c="export MAKEFLAGS=\"-j\$[`getconf _NPROCESSORS_ONLN`*3/2]\"; $c";
     $c="export http_proxy=http://127.0.0.1:3128/; $c";
     $c="set -ex; cd $builddir; $c";
     die "found ': $c" if $c=~/'/;
@@ -287,10 +285,11 @@ for my $distro (@distrouse) {
   if ($baretestsuite) {
     for my $file (@file) {
       my $target="$baretestsuite/$file";
-      if ($file=~m{\Q.patch\E$}) {
+      if ($file=~m{[.](R?)patch$}) {
+       my $R=$1;
        my $fileabs=$file;
        $fileabs=$ENV{"PWD"}."/$fileabs" if $fileabs!~m{^/};
-       spawn "cd $baretestsuite; patch -p1 <$fileabs";
+       spawn "cd $baretestsuite; patch -${R}p1 <$fileabs";
       } else {
        -f $target or $file=~m{/testsuite/} or die "File $file does not exist at $target";
        spawn "rm -f $target; cp -p $file $target";
@@ -311,12 +310,11 @@ for my $distro (@distrouse) {
   my @testinlog;
   if ($component=~/^(?:fedora|rhel)glibc$/) {
     @testinlog=(qr/={20}TESTING DETAILS={17}/,qr/={20}PLT RELOCS END={18}/);
-  } elsif ($component=~/^(?:fedora|rhel)binutils$/) {
-    @testinlog=(qr/={20}TESTING={25}/,qr/={20}TESTING END={21}/);
   }
   if (@testinlog) {
     subst sub { s{^.*?\n($testinlog[0]\n.*\n$testinlog[1]\n).*$}{$1}s; },$log,$out;
   } elsif ($cvsbasedir || $srcrpm) {
+    # Applies both to gdb and binutils.
     spawn "gdbunpack $log";
   }