Browse Source

dpkg-genchanges: Skip files based on the architecture from the filename

Instead of using the architecture from the package in the debian/control
file, just use the one coming from the filename, as we rely too on the
package name from the filename to get to the architecture.
Guillem Jover 11 years ago
parent
commit
61088cb909
2 changed files with 2 additions and 4 deletions
  1. 1 0
      debian/changelog
  2. 1 4
      scripts/dpkg-genchanges.pl

+ 1 - 0
debian/changelog

@@ -65,6 +65,7 @@ dpkg (1.18.0) UNRELEASED; urgency=low
     Regression introduced in dpkg 1.17.7. Closes: #781074
   * Use the checksums files list order when building the Files field to match
     the other Checksum fields in dpkg-genchanges.
+  * Skip files based on the architecture from the filename in dpkg-genchanges.
 
   * Perl modules:
     - Rename and deprecate Dpkg::Gettext _g function with new g_.

+ 1 - 4
scripts/dpkg-genchanges.pl

@@ -59,7 +59,6 @@ my @profiles = get_build_profiles();
 my $changes_format = '1.8';
 
 my %p2f;           # - package to file map, has entries for "packagename"
-my %p2arch;        # - package to arch map
 my %f2seccf;       # - package to section map, from control file
 my %f2pricf;       # - package to priority map, from control file
 my %sourcedefault; # - default values as taken from source (used for Section,
@@ -380,8 +379,6 @@ foreach my $pkg ($control->get_packages()) {
 	next; # and skip it
     }
 
-    $p2arch{$p} = $a;
-
     foreach (keys %{$pkg}) {
 	my $v = $pkg->{$_};
 
@@ -490,7 +487,7 @@ for my $file ($dist->get_files()) {
     my $f = $file->{filename};
 
     if (defined $file->{package} && $file->{package_type} =~ m/^u?deb$/) {
-        my $arch_all = debarch_eq('all', $p2arch{$file->{package}});
+        my $arch_all = debarch_eq('all', $file->{arch});
 
         next if (not ($include & BUILD_ARCH_INDEP) and $arch_all);
         next if (not ($include & BUILD_ARCH_DEP) and not $arch_all);