diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2016-06-05 10:55:13 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2016-06-11 10:37:30 -0700 |
commit | 818031e604a4b6c8764db34b3346e3a1bf9b95be (patch) | |
tree | a85cf6fc2121a85ec007160fc2b7ebd91147cd78 /packaging | |
parent | c580122727bed763ca1bd1ee5bfab29756e9cc69 (diff) | |
download | subsurface-818031e604a4b6c8764db34b3346e3a1bf9b95be.tar.gz |
updated build scripts for Mac
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'packaging')
-rwxr-xr-x | packaging/macosx/make-package.sh | 27 | ||||
-rw-r--r-- | packaging/macosx/sign | 6 |
2 files changed, 20 insertions, 13 deletions
diff --git a/packaging/macosx/make-package.sh b/packaging/macosx/make-package.sh index ad5de26a3..6504e8ccd 100755 --- a/packaging/macosx/make-package.sh +++ b/packaging/macosx/make-package.sh @@ -22,25 +22,32 @@ LIBRARY_PATH=${DIR}/install-root/lib make install # now adjust a few references that macdeployqt appears to miss EXECUTABLE=Subsurface.app/Contents/MacOS/Subsurface -for i in libssh libssrfmarblewidget libgit2; do +for i in libssh libssrfmarblewidget libgit2 libGrantlee_TextDocument.dylib libGrantlee_Templates.dylib; do OLD=$(otool -L ${EXECUTABLE} | grep $i | cut -d\ -f1 | tr -d "\t") - cp ${DIR}/install-root/lib/$(basename ${OLD}) Subsurface.app/Contents/Frameworks - SONAME=$(basename $OLD) - install_name_tool -change ${OLD} @executable_path/../Frameworks/${SONAME} ${EXECUTABLE} - if [[ "$i" = "libssh" ]] ; then - LIBSSH=$(basename ${OLD}) - fi - if [[ "$i" = "libgit2" ]] ; then - install_name_tool -change ${LIBSSH} @executable_path/../Frameworks/${LIBSSH} Subsurface.app/Contents/Frameworks/${SONAME} + if [ ! -z ${OLD} ] ; then + cp ${DIR}/install-root/lib/$(basename ${OLD}) Subsurface.app/Contents/Frameworks + SONAME=$(basename $OLD) + install_name_tool -change ${OLD} @executable_path/../Frameworks/${SONAME} ${EXECUTABLE} + if [[ "$i" = "libssh" ]] ; then + LIBSSH=$(basename ${OLD}) + fi + if [[ "$i" = "libgit2" && ! -z ${LIBSSH} ]] ; then + install_name_tool -change ${LIBSSH} @executable_path/../Frameworks/${LIBSSH} Subsurface.app/Contents/Frameworks/${SONAME} + fi fi done RPATH=$(otool -L ${EXECUTABLE} | grep rpath | cut -d\ -f1 | tr -d "\t" | cut -b 8- ) for i in ${RPATH}; do install_name_tool -change @rpath/$i @executable_path/../Frameworks/$i ${EXECUTABLE} done +MARBLELIB=$(ls Subsurface.app/Contents/Frameworks/libssrfmarblewidget*dylib) +RPATH=$(otool -L ${MARBLELIB} | grep rpath | cut -d\ -f1 | tr -d "\t" | cut -b 8- ) +for i in ${RPATH}; do + install_name_tool -change @rpath/$i @executable_path/../Frameworks/$i ${MARBLELIB} +done # next deal with libGrantlee -LIBG=Subsurface.app/Contents/Frameworks/libGrantlee_Templates.5.dylib +LIBG=$(ls Subsurface.app/Contents/Frameworks/libGrantlee_Templates*dylib) for i in QtScript.framework/Versions/5/QtScript QtCore.framework/Versions/5/QtCore ; do install_name_tool -change @rpath/$i @executable_path/../Frameworks/$i ${LIBG} done diff --git a/packaging/macosx/sign b/packaging/macosx/sign index 9084fec42..8b1b0e853 100644 --- a/packaging/macosx/sign +++ b/packaging/macosx/sign @@ -32,14 +32,14 @@ for i in \ ./Subsurface.app//Contents/Frameworks/QtWebChannel.framework/Versions/5/QtWebChannel \ ./Subsurface.app//Contents/Frameworks/*.dylib do - codesign --keychain /Users/hohndel/Library/Keychains/login.keychain -s Dirk $i + codesign --keychain /Users/hohndel/Library/Keychains/login.keychain -s "Developer ID Application: Dirk Hohndel" $i done echo -- signing plugins for i in $(find ./Subsurface.app/Contents/PlugIns -name \*.dylib -o -name \*.so) do - codesign --keychain /Users/hohndel/Library/Keychains/login.keychain -s Dirk $i + codesign --keychain /Users/hohndel/Library/Keychains/login.keychain -s "Developer ID Application: Dirk Hohndel" $i done echo -- finally sign .app -codesign -v --keychain /Users/hohndel/Library/Keychains/login.keychain -s Dirk ./Subsurface.app +codesign -v --keychain /Users/hohndel/Library/Keychains/login.keychain -s "Developer ID Application: Dirk Hohndel" ./Subsurface.app |