summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2014-01-10 00:50:10 +0100
committerNorbert Thiebaud <nthiebaud@gmail.com>2014-01-10 14:48:11 +0000
commit26f9f060a0a0475d984dfb385e3659e75e5ac2eb (patch)
treeae58661f9211117bd4bae9628ba4c09ae0167a5e
parent943dd8bfd8695f11773b90fbfebd4179eee9f492 (diff)
fix help packaging for Mac OS X language packs
helpcontent was not packaged into the tarball that is extracted into the user's installation directory (and thus never was installed) simplify the packaging by getting rid of the special "collect" dir (LangPackHostName) that was the cause for the problem to begin with: LanguagePack files were collected in LangPackHostName based directory, while HelpPack files were collected in regular directory. And that value wasn't even used for the actual path that is delivered to the user, so get rid of it and the associated code. Change-Id: Iadd24382a45722bbe8d58bd97be79609fd03021b (cherry picked from commit deb39c012031b7981360665cc19dc81d3342a3ad) Reviewed-on: https://gerrit.libreoffice.org/7350 Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com> Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
-rw-r--r--scp2/source/ooo/directory_ooo_macosx.scp1
-rw-r--r--solenv/bin/modules/installer.pm2
-rw-r--r--solenv/bin/modules/installer/scriptitems.pm15
-rw-r--r--solenv/bin/modules/installer/simplepackage.pm25
4 files changed, 12 insertions, 31 deletions
diff --git a/scp2/source/ooo/directory_ooo_macosx.scp b/scp2/source/ooo/directory_ooo_macosx.scp
index 6cd14ab17cf2..0bc7bfd44d25 100644
--- a/scp2/source/ooo/directory_ooo_macosx.scp
+++ b/scp2/source/ooo/directory_ooo_macosx.scp
@@ -22,7 +22,6 @@
Directory gid_Dir_Bundle
ParentID = PD_PROGDIR;
HostName = "%PRODUCTNAME.app";
- LangPackHostName = "%PRODUCTNAME Language Pack.app";
End
Directory gid_Dir_Bundle_Contents
diff --git a/solenv/bin/modules/installer.pm b/solenv/bin/modules/installer.pm
index a081456bed0b..237947d43631 100644
--- a/solenv/bin/modules/installer.pm
+++ b/solenv/bin/modules/installer.pm
@@ -291,8 +291,6 @@ sub run {
my $dirsinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Directory");
- if ( $installer::globals::languagepack ) { installer::scriptitems::use_langpack_hostname($dirsinproductarrayref); }
-
if ( $allvariableshashref->{'SHIFT_BASIS_INTO_BRAND_LAYER'} ) { $dirsinproductarrayref = installer::scriptitems::shift_basis_directory_parents($dirsinproductarrayref); }
if ( $allvariableshashref->{'OFFICEDIRECTORYNAME'} ) { installer::scriptitems::set_officedirectory_name($dirsinproductarrayref, $allvariableshashref->{'OFFICEDIRECTORYNAME'}); }
diff --git a/solenv/bin/modules/installer/scriptitems.pm b/solenv/bin/modules/installer/scriptitems.pm
index 331095149265..4c384ce53e3d 100644
--- a/solenv/bin/modules/installer/scriptitems.pm
+++ b/solenv/bin/modules/installer/scriptitems.pm
@@ -489,21 +489,6 @@ sub get_children
}
################################################################################
-# Using different HostName for language packs
-################################################################################
-
-sub use_langpack_hostname
-{
- my ($dirsref) = @_;
-
- for ( my $i = 0; $i <= $#{$dirsref}; $i++ )
- {
- my $onedir = ${$dirsref}[$i];
- if (( $onedir->{'LangPackHostName'} ) && ( $onedir->{'LangPackHostName'} ne "" )) { $onedir->{'HostName'} = $onedir->{'LangPackHostName'}; }
- }
-}
-
-################################################################################
# Using langpack copy action for language packs
################################################################################
diff --git a/solenv/bin/modules/installer/simplepackage.pm b/solenv/bin/modules/installer/simplepackage.pm
index da58b40753f2..118d420ff074 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -289,23 +289,21 @@ sub create_package
if (( $installer::globals::languagepack ) || ( $installer::globals::helppack ))
{
+ # LanguagePack and HelpPack files are collected in $srcfolder, packaged into
+ # tarball.tar.bz2 and finally the Language Pack.app is assembled in $appfolder
$localtempdir = "$tempdir/$packagename";
- if ( $installer::globals::helppack ) { $volume_name = "$volume_name Help Pack"; }
- if ( $installer::globals::languagepack )
- {
- $volume_name = "$volume_name Language Pack";
- $volume_name_classic = "$volume_name_classic Language Pack";
- $volume_name_classic_app = "$volume_name_classic_app Language Pack";
- }
+ my $srcfolder = $localtempdir . "/" . $volume_name_classic_app . "\.app";
+
+ $volume_name .= " Language Pack";
+ $volume_name_classic .= " Language Pack";
+ $volume_name_classic_app .= " Language Pack";
- # Create tar ball named tarball.tar.bz2
- # my $appfolder = $localtempdir . "/" . $volume_name . "\.app";
my $appfolder = $localtempdir . "/" . $volume_name_classic_app . "\.app";
my $contentsfolder = $appfolder . "/Contents";
my $tarballname = "tarball.tar.bz2";
my $localfrom = cwd();
- chdir $appfolder;
+ chdir $srcfolder;
$systemcall = "tar -cjf $tarballname Contents/";
@@ -325,14 +323,15 @@ sub create_package
push( @installer::globals::logfileinfo, $infoline);
}
- my $sourcefile = $appfolder . "/" . $tarballname;
+ my $sourcefile = $srcfolder . "/" . $tarballname;
my $destfile = $contentsfolder . "/" . $tarballname;
- installer::systemactions::remove_complete_directory($contentsfolder);
+ installer::systemactions::remove_complete_directory($appfolder);
+ installer::systemactions::create_directory($appfolder);
installer::systemactions::create_directory($contentsfolder);
installer::systemactions::copy_one_file($sourcefile, $destfile);
- unlink($sourcefile);
+ installer::systemactions::remove_complete_directory($srcfolder);
# Copy two files into installation set next to the tar ball
# 1. "osx_install.applescript"