summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2001-09-10 15:45:40 +0000
committerPascal Rigaux <pixel@mandriva.com>2001-09-10 15:45:40 +0000
commite4c930e80874953293979f3d91ebd93551bf821c (patch)
tree0081cf8cf30049db679d7a056f4fe82d2d41844a
parent7af00be13aa97e120426fc1cd260f4a71f3c8078 (diff)
downloaddrakx-backup-do-not-use-e4c930e80874953293979f3d91ebd93551bf821c.tar
drakx-backup-do-not-use-e4c930e80874953293979f3d91ebd93551bf821c.tar.gz
drakx-backup-do-not-use-e4c930e80874953293979f3d91ebd93551bf821c.tar.bz2
drakx-backup-do-not-use-e4c930e80874953293979f3d91ebd93551bf821c.tar.xz
drakx-backup-do-not-use-e4c930e80874953293979f3d91ebd93551bf821c.zip
- skip directories missing drakx-help.xml
- convert to the right charset (taken from $lang.po)
-rwxr-xr-xperl-install/share/po/help_xml2pm.pl5
1 files changed, 3 insertions, 2 deletions
diff --git a/perl-install/share/po/help_xml2pm.pl b/perl-install/share/po/help_xml2pm.pl
index d6b0f8b2c..de63bb436 100755
--- a/perl-install/share/po/help_xml2pm.pl
+++ b/perl-install/share/po/help_xml2pm.pl
@@ -5,7 +5,7 @@ use MDK::Common;
my $help;
my $dir = "doc/manual/literal/drakx";
-my @langs = grep { /^..$/ } all($dir) or die "no XML help found in $dir\n";
+my @langs = grep { /^..$/ && -e "$dir/$_/drakx-help.xml" } all($dir) or die "no XML help found in $dir\n";
my %helps = map {
my $lang = $_;
@@ -20,7 +20,8 @@ save_help($base);
foreach my $lang (keys %helps) {
local *F;
- open F, "> help-$lang.pot";
+ my ($charset) = cat_("$lang.po") =~ /charset=([^\\]+)/ or die "missing charset in $lang.po\n";
+ open F, "| iconv -f utf8 -t $charset > help-$lang.pot";
print F "\n";
foreach my $id (keys %{$helps{$lang}}) {
$base->{$id} or die "$lang:$id doesn't exist in english\n";