The branch, master has been updated
       via  98ff0909d51cfe3536b34932207eb0820318bf3e (commit)
       via  4b0164aafcf24a468697589890b1bca9685820b3 (commit)
       via  ac7d8b96b7b86ab74b3448554970b1ba64d4b5dd (commit)
       via  b3fd1ae7a819ab8d1ab89cc3f289e0298ddd56be (commit)
       via  baf956813b135f7688f47bc4faef002234e51af8 (commit)
       via  1f38d79b65fd024883007e712e61a1112566b1a0 (commit)
       via  8fd4c5df34a5b5497584cde7787ef04b5b69aed7 (commit)
      from  1073aae7127d1912acbebbcc6dfd3379b1b06d74 (commit)


- Shortlog ------------------------------------------------------------
98ff090 Bump version to 1.14.11~
4b0164a Release 1.14.10
ac7d8b9 Dpkg::Arch: Make get_host_arch and get_build_arch read from the 
environment
b3fd1ae dpkg-architecture: use a hash instead of independent variables
baf9568 dpkg-gensymbols: Remove duplicated declaration of @librarypaths
1f38d79 Dpkg::Fields: Declare private variable with 'my' instead of 'our'
8fd4c5d dpkg-name: Add support for Package-Type

Summary of changes:
 ChangeLog                    |   49 +++++++++++++++++++++++++
 configure.ac                 |    2 +-
 debian/changelog             |   15 +++++++-
 man/ChangeLog                |    4 ++
 man/dpkg-name.1              |   11 +++---
 scripts/Dpkg/Arch.pm         |   19 ++++++++--
 scripts/Dpkg/Fields.pm       |    2 +-
 scripts/dpkg-architecture.pl |   83 ++++++++++++++++--------------------------
 scripts/dpkg-gensymbols.pl   |    1 -
 scripts/dpkg-name.sh         |   11 ++++--
 10 files changed, 128 insertions(+), 69 deletions(-)
-----------------------------------------------------------------------
Details of changes:

commit 98ff0909d51cfe3536b34932207eb0820318bf3e
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Fri Nov 23 06:51:21 2007 +0200

    Bump version to 1.14.11~

diff --git a/ChangeLog b/ChangeLog
index 6a9bcc9..74dc96e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
 
+       * configure.ac: Bump version to 1.14.11~.
+
+2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
+
        * configure.ac: Release 1.14.10.
 
 2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
diff --git a/configure.ac b/configure.ac
index a2da5a8..07afb54 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
 # Process this file with autoconf to produce a configure script.
 
 AC_PREREQ(2.59)
-AC_INIT([dpkg], [1.14.10], [EMAIL PROTECTED])
+AC_INIT([dpkg], [1.14.11~], [EMAIL PROTECTED])
 AC_CONFIG_SRCDIR([lib/dpkg.h])
 AC_CONFIG_MACRO_DIR([m4])
 AC_CONFIG_AUX_DIR([config])
diff --git a/debian/changelog b/debian/changelog
index 6d7e8da..5eefeec 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+dpkg (1.14.11) UNRELEASED; urgency=low
+
+  *
+
+ -- Guillem Jover <[EMAIL PROTECTED]>  Fri, 23 Nov 2007 06:50:02 +0200
+
 dpkg (1.14.10) unstable; urgency=low
 
   [ Raphael Hertzog ]

commit 4b0164aafcf24a468697589890b1bca9685820b3
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Fri Nov 23 06:32:55 2007 +0200

    Release 1.14.10

diff --git a/ChangeLog b/ChangeLog
index 18c52e3..6a9bcc9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
 
+       * configure.ac: Release 1.14.10.
+
+2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
+
        * scripts/Dpkg/Arch.pm (get_build_arch): Rename to ...
        (get_raw_build_arch): ... this.
        (get_build_arch): New function.
diff --git a/configure.ac b/configure.ac
index 2047356..a2da5a8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
 # Process this file with autoconf to produce a configure script.
 
 AC_PREREQ(2.59)
-AC_INIT([dpkg], [1.14.10~], [EMAIL PROTECTED])
+AC_INIT([dpkg], [1.14.10], [EMAIL PROTECTED])
 AC_CONFIG_SRCDIR([lib/dpkg.h])
 AC_CONFIG_MACRO_DIR([m4])
 AC_CONFIG_AUX_DIR([config])
diff --git a/debian/changelog b/debian/changelog
index 25584a0..6d7e8da 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-dpkg (1.14.10) UNRELEASED; urgency=low
+dpkg (1.14.10) unstable; urgency=low
 
   [ Raphael Hertzog ]
   * dpkg-shlibdeps now correctly identify private libraries (avoid many
@@ -26,7 +26,7 @@ dpkg (1.14.10) UNRELEASED; urgency=low
   [ Added scripts translations ]
   * Swedish (Peter Karlsson)
 
- -- Guillem Jover <[EMAIL PROTECTED]>  Tue, 20 Nov 2007 07:27:44 +0200
+ -- Guillem Jover <[EMAIL PROTECTED]>  Fri, 23 Nov 2007 06:32:27 +0200
 
 dpkg (1.14.9) unstable; urgency=low
 

commit ac7d8b96b7b86ab74b3448554970b1ba64d4b5dd
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Fri Nov 23 04:42:25 2007 +0200

    Dpkg::Arch: Make get_host_arch and get_build_arch read from the environment
    
    All scripts calling get_host_arch are expected to support getting the
    value overriden by the environment when cross building. Except for
    dpkg-architecture, which needs more fine grained control, and calls
    directly the get_raw_ functions.

diff --git a/ChangeLog b/ChangeLog
index 7c950e1..18c52e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,19 @@
 2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
 
+       * scripts/Dpkg/Arch.pm (get_build_arch): Rename to ...
+       (get_raw_build_arch): ... this.
+       (get_build_arch): New function.
+       (get_host_arch): Rename to ...
+       (get_raw_host_arch): ... this. Use get_raw_build_arch instead of
+       get_build_arch.
+       (get_host_arch): New function.
+       (@EXPORT_OK): Add get_raw_build_arch and get_raw_host_arch.
+       * scripts/dpkg-architecture.pl: Import get_raw_build_arch and
+       get_raw_host_arch instead of get_build_arch and get_host_arch.
+       Fix all callers.
+
+2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
+
        * scripts/dpkg-architecture.pl (%env): Rename to ...
        (%v): ... this.
        ($deb_build_arch, $deb_build_arch_os, $deb_build_arch_cpu)
diff --git a/debian/changelog b/debian/changelog
index 5b3a911..25584a0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -17,6 +17,8 @@ dpkg (1.14.10) UNRELEASED; urgency=low
 
   [ Guillem Jover ]
   * Add support for Package-Type in dpkg-name.
+  * Restore cross compilation support by honouring the environment host and
+    arch variables to override the default values on the dpkg-dev scripts.
 
   [ Updated man pages translations ]
   * Swedish (Peter Karlsson)
diff --git a/scripts/Dpkg/Arch.pm b/scripts/Dpkg/Arch.pm
index 080ee59..3cf0a94 100644
--- a/scripts/Dpkg/Arch.pm
+++ b/scripts/Dpkg/Arch.pm
@@ -5,7 +5,8 @@ use warnings;
 
 use Exporter;
 our @ISA = qw(Exporter);
-our @EXPORT_OK = qw(get_build_arch get_host_arch get_gcc_host_gnu_type
+our @EXPORT_OK = qw(get_raw_build_arch get_raw_host_arch
+                    get_build_arch get_host_arch get_gcc_host_gnu_type
                     get_valid_arches debarch_eq debarch_is
                     debarch_to_gnutriplet gnutriplet_to_debarch
                     debtriplet_to_gnutriplet gnutriplet_to_debtriplet
@@ -27,7 +28,7 @@ my %debarch_to_debtriplet;
     my $host_arch;
     my $gcc_host_gnu_type;
 
-    sub get_build_arch()
+    sub get_raw_build_arch()
     {
        return $build_arch if defined $build_arch;
 
@@ -39,6 +40,11 @@ my %debarch_to_debtriplet;
        return $build_arch;
     }
 
+    sub get_build_arch()
+    {
+       return $ENV{DEB_BUILD_ARCH} || get_raw_build_arch();
+    }
+
     sub get_gcc_host_gnu_type()
     {
        return $gcc_host_gnu_type if defined $gcc_host_gnu_type;
@@ -53,7 +59,7 @@ my %debarch_to_debtriplet;
        return $gcc_host_gnu_type;
     }
 
-    sub get_host_arch()
+    sub get_raw_host_arch()
     {
        return $host_arch if defined $host_arch;
 
@@ -77,11 +83,16 @@ my %debarch_to_debtriplet;
 
        if (!defined($host_arch)) {
            # Switch to native compilation.
-           $host_arch = get_build_arch();
+           $host_arch = get_raw_build_arch();
        }
 
        return $host_arch;
     }
+
+    sub get_host_arch()
+    {
+       return $ENV{DEB_HOST_ARCH} || get_raw_host_arch();
+    }
 }
 
 sub get_valid_arches()
diff --git a/scripts/dpkg-architecture.pl b/scripts/dpkg-architecture.pl
index 4cd6cba..90e96c4 100755
--- a/scripts/dpkg-architecture.pl
+++ b/scripts/dpkg-architecture.pl
@@ -25,7 +25,7 @@ use warnings;
 use Dpkg;
 use Dpkg::Gettext;
 use Dpkg::ErrorHandling qw(warning syserr usageerr);
-use Dpkg::Arch qw(get_build_arch get_host_arch get_gcc_host_gnu_type
+use Dpkg::Arch qw(get_raw_build_arch get_raw_host_arch get_gcc_host_gnu_type
                   get_valid_arches debarch_eq debarch_is debarch_to_debtriplet
                   debarch_to_gnutriplet gnutriplet_to_debarch);
 
@@ -130,10 +130,10 @@ my @ordered = qw(DEB_BUILD_ARCH DEB_BUILD_ARCH_OS 
DEB_BUILD_ARCH_CPU
                  DEB_HOST_ARCH DEB_HOST_ARCH_OS DEB_HOST_ARCH_CPU
                  DEB_HOST_GNU_CPU DEB_HOST_GNU_SYSTEM DEB_HOST_GNU_TYPE);
 
-$v{DEB_BUILD_ARCH} = get_build_arch();
+$v{DEB_BUILD_ARCH} = get_raw_build_arch();
 $v{DEB_BUILD_GNU_TYPE} = debarch_to_gnutriplet($v{DEB_BUILD_ARCH});
 
-$v{DEB_HOST_ARCH} = get_host_arch();
+$v{DEB_HOST_ARCH} = get_raw_host_arch();
 $v{DEB_HOST_GNU_TYPE} = debarch_to_gnutriplet($v{DEB_HOST_ARCH});
 
 # Set user values:

commit b3fd1ae7a819ab8d1ab89cc3f289e0298ddd56be
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Fri Nov 23 04:40:01 2007 +0200

    dpkg-architecture: use a hash instead of independent variables
    
    Reduce the code by using a hash to store the build and host architecture
    values, and the values of @ordered as keys.

diff --git a/ChangeLog b/ChangeLog
index 73ace93..7c950e1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,17 @@
 2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
 
+       * scripts/dpkg-architecture.pl (%env): Rename to ...
+       (%v): ... this.
+       ($deb_build_arch, $deb_build_arch_os, $deb_build_arch_cpu)
+       ($deb_build_gnu_cpu, deb_build_gnu_system, deb_build_gnu_type)
+       ($deb_host_arch, $deb_host_arch_os, $deb_host_arch_cpu)
+       ($deb_host_gnu_cpu, $deb_host_gnu_system, $deb_host_gnu_type): Use
+       the %v hash to store those variables using the values from @ordered
+       as keys.
+       ($abi): New variable.
+
+2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
+
        * scripts/dpkg-gensymbols.pl (@librarypaths): Remove duplicated
        declaration.
 
diff --git a/scripts/dpkg-architecture.pl b/scripts/dpkg-architecture.pl
index e44956e..4cd6cba 100755
--- a/scripts/dpkg-architecture.pl
+++ b/scripts/dpkg-architecture.pl
@@ -123,11 +123,18 @@ while (@ARGV) {
 
 # Set default values:
 
-my $deb_build_arch = get_build_arch();
-my $deb_build_gnu_type = debarch_to_gnutriplet($deb_build_arch);
+my %v;
 
-my $deb_host_arch = get_host_arch();
-my $deb_host_gnu_type = debarch_to_gnutriplet($deb_host_arch);
+my @ordered = qw(DEB_BUILD_ARCH DEB_BUILD_ARCH_OS DEB_BUILD_ARCH_CPU
+                 DEB_BUILD_GNU_CPU DEB_BUILD_GNU_SYSTEM DEB_BUILD_GNU_TYPE
+                 DEB_HOST_ARCH DEB_HOST_ARCH_OS DEB_HOST_ARCH_CPU
+                 DEB_HOST_GNU_CPU DEB_HOST_GNU_SYSTEM DEB_HOST_GNU_TYPE);
+
+$v{DEB_BUILD_ARCH} = get_build_arch();
+$v{DEB_BUILD_GNU_TYPE} = debarch_to_gnutriplet($v{DEB_BUILD_ARCH});
+
+$v{DEB_HOST_ARCH} = get_host_arch();
+$v{DEB_HOST_GNU_TYPE} = debarch_to_gnutriplet($v{DEB_HOST_ARCH});
 
 # Set user values:
 
@@ -156,77 +163,49 @@ if ($req_host_gnu_type ne '' && $req_host_arch ne '') {
         if $dfl_host_gnu_type ne $req_host_gnu_type;
 }
 
-$deb_host_arch = $req_host_arch if $req_host_arch ne '';
-$deb_host_gnu_type = $req_host_gnu_type if $req_host_gnu_type ne '';
+$v{DEB_HOST_ARCH} = $req_host_arch if $req_host_arch ne '';
+$v{DEB_HOST_GNU_TYPE} = $req_host_gnu_type if $req_host_gnu_type ne '';
 
 my $gcc = get_gcc_host_gnu_type();
 
 warning(_g("Specified GNU system type %s does not match gcc system type %s."),
-        $deb_host_gnu_type, $gcc)
+        $v{DEB_HOST_GNU_TYPE}, $gcc)
     if !($req_is_arch or $req_eq_arch) &&
-       ($gcc ne '') && ($gcc ne $deb_host_gnu_type);
+       ($gcc ne '') && ($gcc ne $v{DEB_HOST_GNU_TYPE});
 
 # Split the Debian and GNU names
-my ($deb_host_arch_abi, $deb_host_arch_os, $deb_host_arch_cpu) = 
debarch_to_debtriplet($deb_host_arch);
-my ($deb_build_arch_abi, $deb_build_arch_os, $deb_build_arch_cpu) = 
debarch_to_debtriplet($deb_build_arch);
-my ($deb_host_gnu_cpu, $deb_host_gnu_system) = split(/-/, $deb_host_gnu_type, 
2);
-my ($deb_build_gnu_cpu, $deb_build_gnu_system) = split(/-/, 
$deb_build_gnu_type, 2);
-
-my %env = ();
-if (!$force) {
-    $deb_build_arch = $ENV{DEB_BUILD_ARCH} if (exists $ENV{DEB_BUILD_ARCH});
-    $deb_build_arch_os = $ENV{DEB_BUILD_ARCH_OS} if (exists 
$ENV{DEB_BUILD_ARCH_OS});
-    $deb_build_arch_cpu = $ENV{DEB_BUILD_ARCH_CPU} if (exists 
$ENV{DEB_BUILD_ARCH_CPU});
-    $deb_build_gnu_cpu = $ENV{DEB_BUILD_GNU_CPU} if (exists 
$ENV{DEB_BUILD_GNU_CPU});
-    $deb_build_gnu_system = $ENV{DEB_BUILD_GNU_SYSTEM} if (exists 
$ENV{DEB_BUILD_GNU_SYSTEM});
-    $deb_build_gnu_type = $ENV{DEB_BUILD_GNU_TYPE} if (exists 
$ENV{DEB_BUILD_GNU_TYPE});
-    $deb_host_arch = $ENV{DEB_HOST_ARCH} if (exists $ENV{DEB_HOST_ARCH});
-    $deb_host_arch_os = $ENV{DEB_HOST_ARCH_OS} if (exists 
$ENV{DEB_HOST_ARCH_OS});
-    $deb_host_arch_cpu = $ENV{DEB_HOST_ARCH_CPU} if (exists 
$ENV{DEB_HOST_ARCH_CPU});
-    $deb_host_gnu_cpu = $ENV{DEB_HOST_GNU_CPU} if (exists 
$ENV{DEB_HOST_GNU_CPU});
-    $deb_host_gnu_system = $ENV{DEB_HOST_GNU_SYSTEM} if (exists 
$ENV{DEB_HOST_GNU_SYSTEM});
-    $deb_host_gnu_type = $ENV{DEB_HOST_GNU_TYPE} if (exists 
$ENV{DEB_HOST_GNU_TYPE});
-}
+my $abi;
 
-my @ordered = qw(DEB_BUILD_ARCH DEB_BUILD_ARCH_OS DEB_BUILD_ARCH_CPU
-                 DEB_BUILD_GNU_CPU DEB_BUILD_GNU_SYSTEM DEB_BUILD_GNU_TYPE
-                 DEB_HOST_ARCH DEB_HOST_ARCH_OS DEB_HOST_ARCH_CPU
-                 DEB_HOST_GNU_CPU DEB_HOST_GNU_SYSTEM DEB_HOST_GNU_TYPE);
+($abi, $v{DEB_HOST_ARCH_OS}, $v{DEB_HOST_ARCH_CPU}) = 
debarch_to_debtriplet($v{DEB_HOST_ARCH});
+($abi, $v{DEB_BUILD_ARCH_OS}, $v{DEB_BUILD_ARCH_CPU}) = 
debarch_to_debtriplet($v{DEB_BUILD_ARCH});
+($v{DEB_HOST_GNU_CPU}, $v{DEB_HOST_GNU_SYSTEM}) = split(/-/, 
$v{DEB_HOST_GNU_TYPE}, 2);
+($v{DEB_BUILD_GNU_CPU}, $v{DEB_BUILD_GNU_SYSTEM}) = split(/-/, 
$v{DEB_BUILD_GNU_TYPE}, 2);
 
-$env{'DEB_BUILD_ARCH'}=$deb_build_arch;
-$env{'DEB_BUILD_ARCH_OS'}=$deb_build_arch_os;
-$env{'DEB_BUILD_ARCH_CPU'}=$deb_build_arch_cpu;
-$env{'DEB_BUILD_GNU_CPU'}=$deb_build_gnu_cpu;
-$env{'DEB_BUILD_GNU_SYSTEM'}=$deb_build_gnu_system;
-$env{'DEB_BUILD_GNU_TYPE'}=$deb_build_gnu_type;
-$env{'DEB_HOST_ARCH'}=$deb_host_arch;
-$env{'DEB_HOST_ARCH_OS'}=$deb_host_arch_os;
-$env{'DEB_HOST_ARCH_CPU'}=$deb_host_arch_cpu;
-$env{'DEB_HOST_GNU_CPU'}=$deb_host_gnu_cpu;
-$env{'DEB_HOST_GNU_SYSTEM'}=$deb_host_gnu_system;
-$env{'DEB_HOST_GNU_TYPE'}=$deb_host_gnu_type;
+for my $k (@ordered) {
+    $v{$k} = $ENV{$k} if (defined ($ENV{$k}) && !$force);
+}
 
 if ($action eq 'l') {
     foreach my $k (@ordered) {
-       print "$k=$env{$k}\n";
+       print "$k=$v{$k}\n";
     }
 } elsif ($action eq 's') {
     foreach my $k (@ordered) {
-       print "$k=$env{$k}; ";
+       print "$k=$v{$k}; ";
     }
     print "export ".join(" ",@ordered)."\n";
 } elsif ($action eq 'u') {
     print "unset ".join(" ",@ordered)."\n";
 } elsif ($action eq 'e') {
-    exit !debarch_eq($deb_host_arch, $req_eq_arch);
+    exit !debarch_eq($v{DEB_HOST_ARCH}, $req_eq_arch);
 } elsif ($action eq 'i') {
-    exit !debarch_is($deb_host_arch, $req_is_arch);
+    exit !debarch_is($v{DEB_HOST_ARCH}, $req_is_arch);
 } elsif ($action eq 'c') {
-    @ENV{keys %env} = values %env;
+    @ENV{keys %v} = values %v;
     exec @ARGV;
 } elsif ($action eq 'q') {
-    if (exists $env{$req_variable_to_print}) {
-        print "$env{$req_variable_to_print}\n";
+    if (exists $v{$req_variable_to_print}) {
+        print "$v{$req_variable_to_print}\n";
     } else {
         die sprintf(_g("%s is not a supported variable name"), 
$req_variable_to_print);
     }

commit baf956813b135f7688f47bc4faef002234e51af8
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Fri Nov 23 04:39:05 2007 +0200

    dpkg-gensymbols: Remove duplicated declaration of @librarypaths

diff --git a/ChangeLog b/ChangeLog
index e3816e3..73ace93 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
 
+       * scripts/dpkg-gensymbols.pl (@librarypaths): Remove duplicated
+       declaration.
+
+2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
+
        * scripts/Dpkg/Fields.pm (%fieldimps): Declare with 'my' instead
        of 'our'.
 
diff --git a/scripts/dpkg-gensymbols.pl b/scripts/dpkg-gensymbols.pl
index 8186e14..bab05c0 100755
--- a/scripts/dpkg-gensymbols.pl
+++ b/scripts/dpkg-gensymbols.pl
@@ -18,7 +18,6 @@ require 'controllib.pl';
 
 our (%f, %fi);
 our %p2i;
-our @librarypaths;
 
 my $controlfile = 'debian/control';
 my $changelogfile = 'debian/changelog';

commit 1f38d79b65fd024883007e712e61a1112566b1a0
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Fri Nov 23 04:38:06 2007 +0200

    Dpkg::Fields: Declare private variable with 'my' instead of 'our'

diff --git a/ChangeLog b/ChangeLog
index ec356ce..e3816e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-11-23  Guillem Jover  <[EMAIL PROTECTED]>
+
+       * scripts/Dpkg/Fields.pm (%fieldimps): Declare with 'my' instead
+       of 'our'.
+
 2007-11-22  Guillem Jover  <[EMAIL PROTECTED]>
 
        * scripts/dpkg-name.sh (getname): Get the package extension from the
diff --git a/scripts/Dpkg/Fields.pm b/scripts/Dpkg/Fields.pm
index 7602ac1..2896acb 100644
--- a/scripts/Dpkg/Fields.pm
+++ b/scripts/Dpkg/Fields.pm
@@ -12,7 +12,7 @@ sub capit {
     return join '-', @pieces;
 }
 
-our %fieldimps;
+my %fieldimps;
 
 sub set_field_importance(@)
 {

commit 8fd4c5df34a5b5497584cde7787ef04b5b69aed7
Author: Guillem Jover <[EMAIL PROTECTED]>
Date:   Thu Nov 22 04:12:16 2007 +0200

    dpkg-name: Add support for Package-Type

diff --git a/ChangeLog b/ChangeLog
index fc4bb34..ec356ce 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-11-22  Guillem Jover  <[EMAIL PROTECTED]>
+
+       * scripts/dpkg-name.sh (getname): Get the package extension from the
+       Package-Type field, or fallback to deb if not present.
+
 2007-11-22  Raphael Hertzog  <[EMAIL PROTECTED]>
 
        * scripts/dpkg-shlibdeps.pl: Add more debug messages. Accept empty
diff --git a/debian/changelog b/debian/changelog
index 6b64d0f..5b3a911 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -15,6 +15,9 @@ dpkg (1.14.10) UNRELEASED; urgency=low
     orig.tar.{gz,bz2,lzma} file and won't unexpectedly create "Format: 2.0"
     .dsc files.
 
+  [ Guillem Jover ]
+  * Add support for Package-Type in dpkg-name.
+
   [ Updated man pages translations ]
   * Swedish (Peter Karlsson)
 
diff --git a/man/ChangeLog b/man/ChangeLog
index 78eb221..deeaece 100644
--- a/man/ChangeLog
+++ b/man/ChangeLog
@@ -1,3 +1,7 @@
+2007-11-22  Guillem Jover  <[EMAIL PROTECTED]>
+
+       * dpkg-name.1: Document that the Package-Type field is now supported.
+
 2007-11-02  Peter Karlsson  <[EMAIL PROTECTED]>
 
        * po/sv.po: Updated to 1344t.
diff --git a/man/dpkg-name.1 b/man/dpkg-name.1
index 140baff..eb41573 100644
--- a/man/dpkg-name.1
+++ b/man/dpkg-name.1
@@ -3,7 +3,7 @@
 .\"
 .\" This is free software; see the GNU General Public Licence version 2
 .\" or later for copying conditions.  There is NO warranty.
-.TH dpkg\-name 1 "2007-07-18" "Debian Project" "dpkg utilities"
+.TH dpkg\-name 1 "2007-11-22" "Debian Project" "dpkg utilities"
 .SH NAME
 dpkg\-name \- rename Debian packages to full package names
 .
@@ -20,10 +20,11 @@ This manual page documents the
 program which provides an easy way to rename
 .B Debian
 packages into their full package names. A full package name consists
-of \fI<package>_<version>_<architecture>.deb\fP as specified in the control
-file of the package. The \fI<version>\fP part of the filename consists of
-the upstream version information optionally followed by a hyphen and
-the revision information.
+of \fI<package>_<version>_<architecture>.<package_type>\fP as specified in
+the control file of the package. The \fI<version>\fP part of the filename
+consists of the upstream version information optionally followed by a
+hyphen and the revision information. The \fI<package_type>\fP part comes
+from that field if present or fallbacks to \fBdeb\fP.
 .
 .SH OPTIONS
 .TP
diff --git a/scripts/dpkg-name.sh b/scripts/dpkg-name.sh
index 7628693..f2d4922 100755
--- a/scripts/dpkg-name.sh
+++ b/scripts/dpkg-name.sh
@@ -34,7 +34,7 @@ usage () {
        echo "Usage: ${prog} <file>...
 
 ${purpose}
-file.deb changes to <package>_<version>_<architecture>.deb
+file.deb changes to <package>_<version>_<architecture>.<package_type>
 according to the ``underscores convention''.
 
 Options:
@@ -80,11 +80,16 @@ getname () {
                        a=`dpkg --print-architecture`;
                        stderr "assuming architecture \`"$a"' for \`"$1"'";
                fi
+               t=`dpkg-deb -f -- "$1" package-type`
+               if [ -z "$t" ];
+               then
+                       t=deb
+               fi
                if [ -z "$noarchitecture" ];
                then
-                       tname=$p\_$v\_$a.deb;
+                       tname=$p\_$v\_$a.$t;
                else
-                       tname=$p\_$v.deb
+                       tname=$p\_$v.$t
                fi
        
                name=`echo $tname|sed -e 's/ //g'`

-- 
dpkg's main repository


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to