diff options
author | Andras Timar <andras.timar@collabora.com> | 2018-03-15 23:01:27 +0100 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2019-06-15 11:01:58 +0200 |
commit | 9a82f4eed83f194cd45aa31db9773300f6940239 (patch) | |
tree | 803f6ca30f110f692bb7cffcc2ac6a384e7c2e9f /solenv | |
parent | e59c0659990606edea6eff21ee8cf10bad002123 (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: Ia855d7d677136de951c2b9b31ee8d5583475dd41
Diffstat (limited to 'solenv')
-rwxr-xr-x | solenv/bin/macosx-codesign-app-bundle | 4 | ||||
-rw-r--r-- | solenv/bin/modules/installer/simplepackage.pm | 14 |
2 files changed, 11 insertions, 7 deletions
diff --git a/solenv/bin/macosx-codesign-app-bundle b/solenv/bin/macosx-codesign-app-bundle index f5ccff1475f1..a065ecf38b93 100755 --- a/solenv/bin/macosx-codesign-app-bundle +++ b/solenv/bin/macosx-codesign-app-bundle @@ -82,7 +82,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 --force --identifier=$id --sign "$MACOSX_CODESIGNING_IDENTITY" $entitlements "$app" > "/tmp/codesign_${fn}.log" 2>&1 if [ "$?" != "0" ] ; then exit 1 @@ -99,7 +99,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 --force --identifier=$id --sign "$MACOSX_CODESIGNING_IDENTITY" "$version" > "/tmp/codesign_${fn}.log" 2>&1 if [ "$?" != "0" ] ; then exit 1 diff --git a/solenv/bin/modules/installer/simplepackage.pm b/solenv/bin/modules/installer/simplepackage.pm index f5337e59dc18..b407a4ff668f 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; @@ -401,9 +401,12 @@ sub create_package push( @installer::globals::logfileinfo, $infoline); } } - 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") @@ -412,7 +415,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"; @@ -433,7 +437,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 |