Please use this patch instead. This includes stripping the debian.tar.$ext portion. in fixup_pkgv().
On Saturday 05 December 2009 02:16:18 Andres Mejia wrote: > Package: sbuild > Version: 0.59.0-1 > Severity: normal > > > sbuild does not support the new source formats. The following patch fixes > this. > > -- System Information: > Debian Release: squeeze/sid > APT prefers unstable > APT policy: (500, 'unstable'), (1, 'experimental') > Architecture: i386 (i686) > > Kernel: Linux 2.6.31-1-686 (SMP w/2 CPU cores) > Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) > Shell: /bin/sh linked to /bin/dash > > Versions of packages sbuild depends on: > ii adduser 3.111 add and remove users and > groups ii libsbuild-perl 0.59.1~rc1 Tool for building > Debian binary pa ii perl 5.10.1-8 Larry Wall's > Practical Extraction ii perl-modules 5.10.1-8 Core > Perl modules > > Versions of packages sbuild recommends: > ii debootstrap 1.0.20 Bootstrap a basic Debian > system ii fakeroot 1.14.4-1 Gives a fake root > environment > > Versions of packages sbuild suggests: > pn deborphan <none> (no description available) > ii wget 1.12-1.1 retrieves files from the web > > -- no debconf information > -- Regards, Andres
From 6cccbe91eb787cdf3cb77eed10be88e827b64fda Mon Sep 17 00:00:00 2001 From: Andres Mejia <mcita...@gmail.com> Date: Sat, 5 Dec 2009 02:35:09 -0500 Subject: [PATCH] Allow sbuild to support new source formats --- lib/Sbuild/Build.pm | 23 ++++++++++++++++++++--- 1 files changed, 20 insertions(+), 3 deletions(-) diff --git a/lib/Sbuild/Build.pm b/lib/Sbuild/Build.pm index 6aae838..be15fd0 100644 --- a/lib/Sbuild/Build.pm +++ b/lib/Sbuild/Build.pm @@ -572,7 +572,7 @@ sub fetch_source_files { $dsctext =~ /^Files:\s*\n((\s+.*\s*\n)+)/mi and $files = $1; @other_files = map { (split( /\s+/, $_ ))[3] } split( "\n", $files ); - $files =~ /(\Q$pkg\E.*orig.tar.gz)/mi and $orig = $1; + $files =~ /(\Q$pkg\E\.(?:orig\.)?tar\.[a-z\d]+)$/mi and $orig = $1; $self->log_subsubsection("Check arch"); if (!$dscarchs) { @@ -2375,7 +2375,22 @@ sub fixup_pkgv { my $pkgv = shift; $pkgv =~ s,^.*/,,; # strip path - $pkgv =~ s/\.(dsc|diff\.gz|tar\.gz|deb)$//; # strip extension + $pkgv =~ s{ + \. # strip the preceding dot + ( # for grouping the variuos suffixes + dsc| # a dsc + deb| # or deb + diff\.gz| # or diff.gz + debian\.tar\.[a-z\d]+| # or debian.tar.$extension + ( # or some tarball + orig # orig + (-[\w-]+)? # followed by component part 0 or 1 time + \. # followed by a dot + )? # matches 0 time for native, 1 time for upstream + tar # tar portion + \.[a-z\d]+ # matches any extension like gz, bz2, etc. + )$ # must be at the end of the line + }{}x; # strip extension $pkgv =~ s/_[a-zA-Z\d+~-]+\.(changes|deb)$//; # strip extension return $pkgv; @@ -2510,8 +2525,10 @@ sub dsc_files { my $stanza = @{$stanzas}[0]; # We're only interested in the name of the files in the Files field. + my $source = ${$stanza}{'Source'}; + $source =~ s/\s+//msg; my $entry = ${$stanza}{'Files'}; - @files = grep(/\.tar\.gz$|\.diff\.gz$/, split(/\s/, $entry)); + @files = grep(/$source/, split(/\s+/, $entry)); return @files; } -- 1.6.5.4