Package: apt-rdepends
Version: 1.3.0-1

When having the locale set to another language than english apt-rdepends
does not give the expected output.

A simple patch to fix the problem is attached. It might, or might not
need some work. The whole script is a hack anyway, the way I understand
it.

See for example the following two runs:

"
leka% apt-rdepends --reverse --show=Suggests,Recommends nscd
Läser paketlistor... Färdig
Bygger beroendeträd... Färdig
nscd
leka% ./patched-apt-rdepends --reverse --show=Suggests,Recommends nscd
Reading Package Lists... Done
Building Dependency Tree... Done
nscd
  Reverse Suggests: libnss-mdns (0.6-1)
  Reverse Recommends: education-common (0.803)
  Reverse Recommends: libnss-ldap (238-1)
"

As a side effect, the output from apt-rdepends is not localized, but I'd
rather have correct english output than no output at all.
--
/Martin
--- /usr/bin/apt-rdepends       2005-09-21 23:11:57.000000000 +0200
+++ apt-rdepends        2005-10-05 20:15:45.381693974 +0200
@@ -53,6 +53,11 @@
 # The object that knows how to display $output
 my $Print;
 
+# This script depends highly on that no function return localized data.
+require 5.004;
+use POSIX qw(locale_h);
+setlocale(LC_ALL, "C");
+
 GetOptions ('reverse|r'        => \$reverse,
            'build-depends|b'  => \$builddep,
            'dotty|d'          => sub { $output = "dotty" },

Reply via email to