[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-4.1' - 2 commits - solenv/bin sysui/desktop

2014-02-23 Thread Tor Lillqvist
 solenv/bin/macosx-codesign-app-bundle |2 +-
 sysui/desktop/macosx/Info.plist   |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit a5f8d1bafafd56db57f85fddaf90d6039a5720be
Author: Tor Lillqvist t...@collabora.com
Date:   Sun Feb 23 21:05:34 2014 +0200

Use different CFBundleSignature than upstream

CFBundleSignature is an obsolete concept anyway, it is fine to use
'' apparently.

Change-Id: Ifc16e834739a5d7ee5fc5d99a3e3469f2aafa0ee

diff --git a/sysui/desktop/macosx/Info.plist b/sysui/desktop/macosx/Info.plist
index 9682cb0..6a7bb9a 100755
--- a/sysui/desktop/macosx/Info.plist
+++ b/sysui/desktop/macosx/Info.plist
@@ -1415,7 +1415,7 @@
keyCFBundlePackageType/key
stringAPPL/string
keyCFBundleSignature/key
-   stringLibO/string
+   string/string
keyLSRequiresCarbon/key
string1/string
keyNSPrincipalClass/key
commit 568783cb7a93b8f2fcad67ebd32ff4220b05a7e9
Author: Tor Lillqvist t...@collabora.com
Date:   Sun Feb 23 21:03:45 2014 +0200

Include the directory names in the ids to make them unique

There are lots of files with the same name, especially in an app
bundle that includes help in multiple languages.

Change-Id: I66cd2e3c3f22d681d88d02da6fd48ab9651c6f67

diff --git a/solenv/bin/macosx-codesign-app-bundle 
b/solenv/bin/macosx-codesign-app-bundle
index 48454a3..f01a5cf 100755
--- a/solenv/bin/macosx-codesign-app-bundle
+++ b/solenv/bin/macosx-codesign-app-bundle
@@ -39,7 +39,7 @@ find $APP_BUNDLE \( -name '*.dylib' -or -name '*.dylib.*' 
-or -name '*.so' \
 -or -name '*.jar' -or -name '*.jnilib' -or -name 'LICENSE' -or -name 
'LICENSE.html' \
 -or -name '*.applescript' \) ! -type l | grep -v 
LibreOfficePython\.framework |
 while read dylib; do
-id=`basename $dylib`
+id=`echo ${dylib#${APP_BUNDLE}/Contents/} | sed -e 's,/,.,g'`
 codesign --verbose --identifier=$MACOSX_BUNDLE_IDENTIFIER.$id --sign 
$MACOSX_CODESIGNING_IDENTITY $dylib
 done
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-4.1' - 2 commits - solenv/bin

2014-02-10 Thread Tor Lillqvist
 solenv/bin/macosx-codesign-app-bundle |   33 --
 solenv/bin/modules/installer/simplepackage.pm |4 +--
 2 files changed, 23 insertions(+), 14 deletions(-)

New commits:
commit c8e0e5858f7cb5d6269d2b71b735ca14dad10921
Author: Tor Lillqvist t...@collabora.com
Date:   Tue Feb 11 00:30:23 2014 +0200

Handle app bundles with space in name, also sign the mdimporter properly

Just like the Python framework, also the Spotlight importer needs to
be signed specially, it seems.

I wondoer if we could get rid of all the hair in this script by simply
just signing the app bundle, with the --deep option?

Change-Id: I722b4403e74560f6555a7528005ed7aa0c94352b

diff --git a/solenv/bin/macosx-codesign-app-bundle 
b/solenv/bin/macosx-codesign-app-bundle
index 4197780..48454a3 100755
--- a/solenv/bin/macosx-codesign-app-bundle
+++ b/solenv/bin/macosx-codesign-app-bundle
@@ -19,7 +19,7 @@ for V in \
 fi
 done
 
-APP_BUNDLE=$1
+APP_BUNDLE=$1
 
 # Sign dylibs
 #
@@ -34,8 +34,8 @@ APP_BUNDLE=$1
 # add some where it makes sense. Make a depth-first search to sign the contents
 # of e.g. the spotlight plugin before attempting to sign the plugin itself
 
-find $APP_BUNDLE \( -name '*.dylib' -or -name '*.dylib.*' -or -name '*.so' \
--or -name '*.fodt' -or -name 'schema.strings' -or -name 'schema.xml' 
-or -name '*.mdimporter' \
+find $APP_BUNDLE \( -name '*.dylib' -or -name '*.dylib.*' -or -name '*.so' \
+-or -name '*.fodt' -or -name 'schema.strings' -or -name 'schema.xml' \
 -or -name '*.jar' -or -name '*.jnilib' -or -name 'LICENSE' -or -name 
'LICENSE.html' \
 -or -name '*.applescript' \) ! -type l | grep -v 
LibreOfficePython\.framework |
 while read dylib; do
@@ -47,23 +47,31 @@ done
 # gb_LinkTarget__command_dynamiclink in
 # solenv/gbuild/platform/macosx.mk.
 
-# Sign frameworks.
-#
+# Sign included bundles. First frameworks.
+
 # Yeah, we don't bundle any other framework than our Python one, and
 # it has just one version, so this generic search is mostly for
 # completeness.
 
-for framework in `find $APP_BUNDLE -name '*.framework' -type d`; do
-fn=$(basename $framework)
+find $APP_BUNDLE -name '*.framework' -type d |
+while read framework; do
+fn=`basename $framework`
 fn=${fn%.*}
-for version in $framework/Versions/*; do
-if test ! -L $version -a -d $version; then
-codesign --verbose --prefix=$MACOSX_BUNDLE_IDENTIFIER. --sign 
$MACOSX_CODESIGNING_IDENTITY $version/$fn
-   codesign --verbose --prefix=$MACOSX_BUNDLE_IDENTIFIER. --sign 
$MACOSX_CODESIGNING_IDENTITY $version
+for version in $framework/Versions/*; do
+if test ! -L $version -a -d $version; then
+codesign --verbose --prefix=$MACOSX_BUNDLE_IDENTIFIER. --sign 
$MACOSX_CODESIGNING_IDENTITY $version/$fn
+codesign --verbose --prefix=$MACOSX_BUNDLE_IDENTIFIER. --sign 
$MACOSX_CODESIGNING_IDENTITY $version
 fi
 done
 done
 
+# Then mdimporters
+
+find $APP_BUNDLE -name '*.mdimporter' -type d |
+while read bundle; do
+codesign --verbose --prefix=$MACOSX_BUNDLE_IDENTIFIER. --sign 
$MACOSX_CODESIGNING_IDENTITY $bundle
+done
+
 # Sign the app bundle as a whole which means (re-)signing the
 # CFBundleExecutable from Info.plist, i.e. soffice, plus the contents
 # of the Resources tree (which unless you used
@@ -80,6 +88,7 @@ if test $ENABLE_MACOSX_SANDBOX = YES; then
 entitlements=--entitlements $BUILDDIR/lo.xcent
 fi
 
-codesign --force --verbose 
--identifier=${MACOSX_BUNDLE_IDENTIFIER}.$(basename ${APP_BUNDLE}) 
--resource-rules $SRCDIR/setup_native/source/mac/CodesignRules.plist --sign 
$MACOSX_CODESIGNING_IDENTITY $entitlements $APP_BUNDLE
+id=`basename $APP_BUNDLE`
+codesign --force --verbose --identifier=${MACOSX_BUNDLE_IDENTIFIER}.$id 
--resource-rules $SRCDIR/setup_native/source/mac/CodesignRules.plist --sign 
$MACOSX_CODESIGNING_IDENTITY $entitlements $APP_BUNDLE
 
 exit 0
commit 40f4ec95acb1e28b1ba08a3a8259e5877bfc8c16
Author: Tor Lillqvist t...@collabora.com
Date:   Mon Feb 10 18:56:40 2014 +0200

Hardcode app bundle name here, too

Change-Id: I69cabd516e7c40b7ee75e311d725f6db78519855

diff --git a/solenv/bin/modules/installer/simplepackage.pm 
b/solenv/bin/modules/installer/simplepackage.pm
index b2ef9f4..23a1f7b 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -401,10 +401,10 @@ sub create_package
 }
 else
 {
-if (($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev') 
+if (($volume_name_classic_app eq 'LibreOffice from Collabora' || 
$volume_name_classic_app eq 'LibreOfficeDev') 
 defined($ENV{'MACOSX_CODESIGNING_IDENTITY'})  
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne  )
 {
-$systemcall = 
$ENV{'SRCDIR'}/solenv/bin/macosx-codesign-app-bundle