summaryrefslogtreecommitdiff
path: root/solenv
diff options
context:
space:
mode:
authorAndras Timar <andras.timar@collabora.com>2015-11-01 22:14:50 +0100
committerAndras Timar <andras.timar@collabora.com>2016-06-11 12:54:13 +0200
commitf77614d2874cd09b66c9179003716d48e72f3bc1 (patch)
tree4be5123af2b94bb9bf320b1c56b569acc94c1639 /solenv
parent8988a747cb8937da96f4f2b5164b393fb988f6f5 (diff)
Collabora Office OS X packaging
- added EULA (sla.r) in special OS X resource fork format - added volume icon which does not work ATM, TODO later - new dmg background image and adjusted .DS_Store - fixes to tolerate space in app bundle name Change-Id: I3f341bfcd5bea88681e57b314f6069be107c5c2b (cherry picked from commit 26d77ceefcb59a95fff71c730d798d6b59021fc0)
Diffstat (limited to 'solenv')
-rwxr-xr-xsolenv/bin/macosx-codesign-app-bundle6
-rw-r--r--solenv/bin/modules/installer/simplepackage.pm14
2 files changed, 12 insertions, 8 deletions
diff --git a/solenv/bin/macosx-codesign-app-bundle b/solenv/bin/macosx-codesign-app-bundle
index 23fe2bea6e7a..93f3116733ec 100755
--- a/solenv/bin/macosx-codesign-app-bundle
+++ b/solenv/bin/macosx-codesign-app-bundle
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/bash -x
# Script to sign executables, dylibs and frameworks in an app bundle
# plus the bundle itself. Called from
@@ -69,7 +69,7 @@ while read app; do
fn=`basename "$app"`
fn=${fn%.*}
# Assume the app has a XML (and not binary) Info.plist
- id=`grep -A 1 '<key>CFBundleIdentifier</key>' $app/Contents/Info.plist | tail -1 | sed -e 's,.*<string>,,' -e 's,</string>.*,,'`
+ id=`grep -A 1 '<key>CFBundleIdentifier</key>' "$app/Contents/Info.plist" | tail -1 | sed -e 's,.*<string>,,' -e 's,</string>.*,,'`
codesign --verbose --identifier=$id --sign "$MACOSX_CODESIGNING_IDENTITY" $entitlements "$app"
done
@@ -82,7 +82,7 @@ while read framework; do
for version in "$framework"/Versions/*; do
if test ! -L "$version" -a -d "$version"; then
# Assume the framework has a XML (and not binary) Info.plist
- id=`grep -A 1 '<key>CFBundleIdentifier</key>' $version/Resources/Info.plist | tail -1 | sed -e 's,.*<string>,,' -e 's,</string>.*,,'`
+ id=`grep -A 1 '<key>CFBundleIdentifier</key>' "$version/Resources/Info.plist" | tail -1 | sed -e 's,.*<string>,,' -e 's,</string>.*,,'`
codesign --verbose --identifier=$id --sign "$MACOSX_CODESIGNING_IDENTITY" "$version"
fi
done
diff --git a/solenv/bin/modules/installer/simplepackage.pm b/solenv/bin/modules/installer/simplepackage.pm
index ac337988af6e..d4231e1aed45 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -282,7 +282,7 @@ sub create_package
if ( ! $allvariables->{'HIDELICENSEDIALOG'} )
{
- installer::scriptitems::get_sourcepath_from_filename_and_includepath( \$sla, $includepatharrayref, 0);
+ $ref = installer::scriptitems::get_sourcepath_from_filename_and_includepath( \$sla, $includepatharrayref, 0);
}
my $localtempdir = $tempdir;
@@ -393,9 +393,12 @@ sub create_package
chdir $localfrom;
}
- elsif ($volume_name_classic_app eq 'LibreOffice' || $volume_name_classic_app eq 'LibreOfficeDev')
+ elsif ($volume_name_classic_app eq 'Collabora Office')
{
- my $subdir = "$tempdir/$packagename/$volume_name_classic_app.app/Contents/Resources";
+ my $oldappdir = "$tempdir/$packagename/CollaboraOffice.app";
+ my $newappdir = "$tempdir/$packagename/Collabora Office.app";
+ installer::systemactions::rename_directory($oldappdir,$newappdir);
+ my $subdir = "$newappdir/Contents/Resources";
if ( ! -d $subdir ) { installer::systemactions::create_directory($subdir); }
# iterate over OS X localizations
foreach $lang ("ca", "cs", "da", "de", "el", "en", "es", "fi", "fr", "hr", "hu", "id", "it", "ja", "ko", "ms", "nl", "no", "pl", "pt", "pt_PT", "ro", "ru", "sk", "sv", "th", "tr", "uk", "vi", "zh_CN", "zh_TW")
@@ -404,7 +407,8 @@ sub create_package
}
if ( defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && $ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
{
- $systemcall = "$ENV{'SRCDIR'}/solenv/bin/macosx-codesign-app-bundle $localtempdir/$folder/$volume_name_classic_app.app";
+ $newappdir =~ s/ /\\ /g;
+ $systemcall = "$ENV{'SRCDIR'}/solenv/bin/macosx-codesign-app-bundle $newappdir";
print "... $systemcall ...\n";
my $returnvalue = system($systemcall);
$infoline = "Systemcall: $systemcall\n";
@@ -425,7 +429,7 @@ sub create_package
$systemcall = "cd $localtempdir && hdiutil create -megabytes 1500 -srcfolder $folder $archive -ov -fs HFS+ -volname \"$volume_name\" -format UDBZ";
if (( $ref ne "" ) && ( $$ref ne "" )) {
- $systemcall .= " && hdiutil unflatten $archive && Rez -a $$ref -o $archive && hdiutil flatten $archive &&";
+ $systemcall .= " && hdiutil unflatten $archive && Rez -a $$ref -o $archive && hdiutil flatten $archive";
}
}
else