Mercurial > hg > sonic-visualiser
view deploy/osx/sign.sh @ 2265:d33dff02b39b sandbox-notarize
Work on sandboxing (possibly) and using the hardened runtime for notarization. Supply appropriate bundle ID for helpers as well as main application, and request inherited sandbox entitlements. Currently works with sandboxing (apparently) but not yet with the hardened runtime, where we can't load plugins signed by third parties even with the com.apple.security.cs.disable-library-validation entitlement because their team IDs don't match the host. Possibly that exception is supposed to be requested some other way?
author | Chris Cannam |
---|---|
date | Thu, 25 Apr 2019 16:46:02 +0100 |
parents | 4f4eb416fcb4 |
children |
line wrap: on
line source
#!/bin/bash -x set -eu # Execute this from the top-level directory of the project (the one # that contains the .app bundle). Supply the name of the .app bundle # as argument dir="$1" if [ -z "$dir" ] || [ ! -d "$dir" ]; then echo "Usage: $0 <pkgdir>" echo "Where pkgdir is the directory containing <MyApplication>.app" echo "All .app bundles in pkgdir will be signed" exit 2 fi # NB at some point we are going to have to include "--options runtime" # in all of these codesign invocations, and figure out what to do # about signing plugins... id="Developer ID Application: Chris Cannam" opts="-fv --deep --options runtime -i org.sonicvisualiser.SonicVisualiser" eopts="--entitlements deploy/osx/Entitlements.plist" hopts="--entitlements deploy/osx/Entitlements-helpers.plist" for app in "$dir"/*.app; do find "$app" -name \*.dylib -print | while read fr; do codesign -s "$id" $opts "$fr" done codesign -s "$id" $opts $hopts "$app/Contents/Resources/vamp-plugin-load-checker" codesign -s "$id" $opts $hopts "$app/Contents/Resources/piper-vamp-simple-server" codesign -s "$id" $opts $eopts "$app/Contents/MacOS/Sonic Visualiser" done