[Libreoffice-commits] .: solenv/bin
Petr Mladek
pmladek at kemper.freedesktop.org
Wed Mar 30 08:20:05 PDT 2011
solenv/bin/modules/installer/worker.pm | 16 ++++++++++++++--
1 file changed, 14 insertions(+), 2 deletions(-)
New commits:
commit b9ba2b739ae709d3b7586aa80e2c86350e92344f
Author: Petr Mladek <pmladek at suse.cz>
Date: Wed Mar 30 17:19:03 2011 +0200
solenv-installer-cleaner-paths.diff: do not create '.' subdirectories
omit './' in paths
diff --git a/solenv/bin/modules/installer/worker.pm b/solenv/bin/modules/installer/worker.pm
index 4c7d7cd..4ab838e 100644
--- a/solenv/bin/modules/installer/worker.pm
+++ b/solenv/bin/modules/installer/worker.pm
@@ -719,8 +719,16 @@ sub install_simple ($$$$$$)
if ((!($dir =~ /\bPREDEFINED_/ )) || ( $dir =~ /\bPREDEFINED_PROGDIR\b/ ))
{
- mkdir $destdir . $onedir->{'HostName'};
- push @lines, "%dir " . $onedir->{'HostName'} . "\n";
+ my $hostname = $onedir->{'HostName'};
+
+ # ignore '.' subdirectories
+ next if ( $hostname =~ m/\.$/ );
+ # remove './' from the path
+ $hostname =~ s/\.\///g;
+
+ # printf "mkdir $destdir$hostname\n";
+ mkdir $destdir . $hostname;
+ push @lines, "%dir " . $hostname . "\n";
}
}
@@ -737,6 +745,10 @@ sub install_simple ($$$$$$)
$destination =~ s/\$\$/\$/;
$sourcepath =~ s/\$\$/\$/;
+ # remove './' from the path
+ $sourcepath =~ s/\.\///g;
+ $destination =~ s/\.\///g;
+
push @lines, "$destination\n";
if(-d "$destdir$destination"){
rmtree("$destdir$destination");
More information about the Libreoffice-commits
mailing list