]> ruderich.org/simon Gitweb - blhc/blhc.git/blobdiff - bin/blhc
Fix architecture detection with recent dpkg-buildpackage versions
[blhc/blhc.git] / bin / blhc
index 17944127a9e1f60db42761790ca44797f6724f55..43000271861b6512d66543e6104361a9d9f15736 100755 (executable)
--- a/bin/blhc
+++ b/bin/blhc
@@ -954,6 +954,10 @@ foreach my $file (@ARGV) {
 
         # Detect architecture automatically unless overridden.
         if (not $arch
+                and index($line, 'dpkg-buildpackage: info: host architecture ') == 0) {
+            $arch = substr $line, 43, -1; # -1 to ignore '\n' at the end
+        # Older versions of dpkg-buildpackage
+        } elsif (not $arch
                 and index($line, 'dpkg-buildpackage: host architecture ') == 0) {
             $arch = substr $line, 37, -1; # -1 to ignore '\n' at the end