summaryrefslogtreecommitdiffstats
path: root/perl-install/lang.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2001-01-04 19:34:30 +0000
committerPascal Rigaux <pixel@mandriva.com>2001-01-04 19:34:30 +0000
commit9887fe04751edf39e8389f2c3ec3f020b5e1c17d (patch)
tree1bccff5e0f3a44ece23808f6a5dd427f1342a434 /perl-install/lang.pm
parent490d1edddbdc645d015e8ad6debc72119d9de8db (diff)
downloaddrakx-9887fe04751edf39e8389f2c3ec3f020b5e1c17d.tar
drakx-9887fe04751edf39e8389f2c3ec3f020b5e1c17d.tar.gz
drakx-9887fe04751edf39e8389f2c3ec3f020b5e1c17d.tar.bz2
drakx-9887fe04751edf39e8389f2c3ec3f020b5e1c17d.tar.xz
drakx-9887fe04751edf39e8389f2c3ec3f020b5e1c17d.zip
keep $o->{langs} unpacked to simplify things
Diffstat (limited to 'perl-install/lang.pm')
-rw-r--r--perl-install/lang.pm21
1 files changed, 2 insertions, 19 deletions
diff --git a/perl-install/lang.pm b/perl-install/lang.pm
index ebea1a86a..a282c444a 100644
--- a/perl-install/lang.pm
+++ b/perl-install/lang.pm
@@ -302,28 +302,11 @@ sub pack_langs {
join ':', uniq(map { $languages{$_}[3] } @$l);
}
-sub unpack_langs {
- my ($langs) = @_;
- [
- $langs eq 'all' ?
- map { $_->[2] } values %languages :
- split(':', $langs)
- ];
-}
-
-sub unpack_lang_codes {
- my ($langs) = @_;
- [
- $langs eq 'all' ?
- map { substr($_->[2], 0, 2) } values %languages :
- split(':', $langs)
- ];
-}
-
sub write_langs {
my ($prefix, $langs) = @_;
+ my $s = pack_langs($langs);
symlink "$prefix/etc/rpm", "/etc/rpm" if $prefix;
- substInFile { s/%_install_langs.*//; $_ .= "%_install_langs $langs\n" if eof } "$prefix/etc/rpm/macros";
+ substInFile { s/%_install_langs.*//; $_ .= "%_install_langs $s\n" if eof } "$prefix/etc/rpm/macros";
}
sub write {