[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] Debian package checker branch, master, updated. 2.3.4-61-ge81e55d



The following commit has been merged in the master branch:
commit e81e55d3deafed7e1ca13093d9c78c41cc3d115b
Author: Adam D. Barratt <adam@adam-barratt.org.uk>
Date:   Sun Mar 28 18:08:46 2010 +0100

    Support source packages using .tar.xz tarballs (#575633)
    
    * unpack/unpack-srcpkg-l1:
      + [ADB] Support tarballs in the .tar.xz format.  (Closes: #575633)

diff --git a/debian/changelog b/debian/changelog
index 88477a0..aa3b0c7 100755
--- a/debian/changelog
+++ b/debian/changelog
@@ -86,6 +86,8 @@ lintian (2.4.0) UNRELEASED; urgency=low
   * unpack/unpack-changes-l1:
     + [ADB] New script to "unpack" a .changes file, creating a fields/
       hierarchy
+  * unpack/unpack-srcpkg-l1:
+    + [ADB] Support tarballs in the .tar.xz format.  (Closes: #575633)
 
  -- Russ Allbery <rra@debian.org>  Tue, 23 Mar 2010 17:35:12 -0700
 
diff --git a/unpack/unpack-srcpkg-l1 b/unpack/unpack-srcpkg-l1
index 49501b2..3046035 100755
--- a/unpack/unpack-srcpkg-l1
+++ b/unpack/unpack-srcpkg-l1
@@ -79,7 +79,7 @@ for my $fs (split(/\n/,$data->{'files'})) {
     next if $fs =~ /^$/o;
     my @t = split(/\s+/o,$fs);
     next if ($t[2] =~ m,/,);
-    if ($t[2] =~ /^(\Q$base\E\.orig|\Q$baserev\E)\.tar\.(gz|bz2|lzma)$/) {
+    if ($t[2] =~ /^(\Q$base\E\.orig|\Q$baserev\E)\.tar\.(gz|bz2|lzma|xz)$/) {
         $tarball = $t[2];
     }
     symlink("$dir/$t[2]", "$base_dir/$t[2]")
@@ -90,13 +90,13 @@ if (!$tarball) {
 }
 
 # Collect a list of the files in the source package.  tar currently doesn't
-# automatically recognize LZMA, so we need to add the option where it's
+# automatically recognize LZMA / XZ, so we need to add the option where it's
 # needed.  Change hard link status (h) to regular files and remove a leading
 # ./ prefix on filenames while we're reading the tar output.  We intentionally
 # don't parallelize this job because we need to use the output below.
 my @tar_options = ('-tvf');
-if ($tarball =~ /\.lzma\z/) {
-    unshift(@tar_options, '--lzma');
+if ($tarball =~ /\.(lzma|xz)\z/) {
+    unshift(@tar_options, "--$1");
 }
 my @index;
 my $last = '';

-- 
Debian package checker


Reply to: