From bed90e0b52647e0c61702d680495c8acec044b73 Mon Sep 17 00:00:00 2001 From: Andras Timar Date: Thu, 15 Mar 2018 23:01:27 +0100 Subject: [cp] Collabora Office macOS 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 --- solenv/bin/macosx-codesign-app-bundle | 4 ++-- solenv/bin/modules/installer/simplepackage.pm | 12 ++++++++---- 2 files changed, 10 insertions(+), 6 deletions(-) (limited to 'solenv') diff --git a/solenv/bin/macosx-codesign-app-bundle b/solenv/bin/macosx-codesign-app-bundle index b79c3d8003b3..47c07d4671b5 100755 --- a/solenv/bin/macosx-codesign-app-bundle +++ b/solenv/bin/macosx-codesign-app-bundle @@ -69,7 +69,7 @@ done find "$APP_BUNDLE"/Contents -name '*.app' -type d | while read app; do # Assume the app has a XML (and not binary) Info.plist - id=`grep -A 1 'CFBundleIdentifier' $app/Contents/Info.plist | tail -1 | sed -e 's,.*,,' -e 's,.*,,'` + id=`grep -A 1 'CFBundleIdentifier' "$app/Contents/Info.plist" | tail -1 | sed -e 's,.*,,' -e 's,.*,,'` codesign --options=runtime --force --identifier=$id --sign "$MACOSX_CODESIGNING_IDENTITY" $entitlements "$app" || exit 1 done @@ -80,7 +80,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 'CFBundleIdentifier' $version/Resources/Info.plist | tail -1 | sed -e 's,.*,,' -e 's,.*,,'` + id=`grep -A 1 'CFBundleIdentifier' "$version/Resources/Info.plist" | tail -1 | sed -e 's,.*,,' -e 's,.*,,'` if test -d $version/bin; then # files in bin are not covered by signing the framework... for scriptorexecutable in $(find $version/bin/ -type f); do diff --git a/solenv/bin/modules/installer/simplepackage.pm b/solenv/bin/modules/installer/simplepackage.pm index 5ab12978362d..687d114a05b8 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; @@ -402,13 +402,17 @@ 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); } if ( $ENV{'MACOSX_CODESIGNING_IDENTITY'} ) { - $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"; $infoline = "Systemcall: $systemcall\n"; push( @installer::globals::logfileinfo, $infoline); -- cgit