summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2001-03-17 17:27:42 +0000
committerPascal Rigaux <pixel@mandriva.com>2001-03-17 17:27:42 +0000
commit268207c62bd77db4d8a63b70c616b09ceb535446 (patch)
tree3823372a0762f81d32dff7a41dcdbbbb272148b1
parent92c9fb29716e67e38d153868351cb63dca6a5bc1 (diff)
downloaddrakx-268207c62bd77db4d8a63b70c616b09ceb535446.tar
drakx-268207c62bd77db4d8a63b70c616b09ceb535446.tar.gz
drakx-268207c62bd77db4d8a63b70c616b09ceb535446.tar.bz2
drakx-268207c62bd77db4d8a63b70c616b09ceb535446.tar.xz
drakx-268207c62bd77db4d8a63b70c616b09ceb535446.zip
(write_langs): in case of empty %_install_langs, don't write it
-rw-r--r--perl-install/lang.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/perl-install/lang.pm b/perl-install/lang.pm
index 45e3720f2..9dbeeb4cd 100644
--- a/perl-install/lang.pm
+++ b/perl-install/lang.pm
@@ -345,7 +345,7 @@ 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 $s\n" if eof } "$prefix/etc/rpm/macros";
+ substInFile { s/%_install_langs.*//; $_ .= "%_install_langs $s\n" if eof && $s } "$prefix/etc/rpm/macros";
}
sub write {