From 6499c248c1072eaa4c68ad20b211c09ed360e35b Mon Sep 17 00:00:00 2001 From: Sergey Minakov Date: Sun, 28 Feb 2021 03:48:29 +0300 Subject: [PATCH] macOS runtime entitlements Enables permission request to camera and microphone for signed .app --- build-macosx/editor.entitlements | 10 ++++++++++ build-release.sh | 3 ++- 2 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 build-macosx/editor.entitlements diff --git a/build-macosx/editor.entitlements b/build-macosx/editor.entitlements new file mode 100644 index 0000000..265a4cd --- /dev/null +++ b/build-macosx/editor.entitlements @@ -0,0 +1,10 @@ + + + + + com.apple.security.device.audio-input + + com.apple.security.device.camera + + + diff --git a/build-release.sh b/build-release.sh index 7e2bf51..35691fe 100755 --- a/build-release.sh +++ b/build-release.sh @@ -152,10 +152,11 @@ if [ "${build_classical}" == "1" ]; then osx_tmpdir=$(ssh "${OSX_HOST}" "mktemp -d") scp "${reldir}/${binname}.zip" "${OSX_HOST}:${osx_tmpdir}" + scp "${basedir}/build-macosx/editor.entitlements" "${OSX_HOST}:${osx_tmpdir}" ssh "${OSX_HOST}" " cd ${osx_tmpdir} && \ unzip ${binname}.zip &&\ - codesign --timestamp --options=runtime -s ${OSX_KEY_ID} -v Godot.app/Contents/MacOS/Godot && \ + codesign --timestamp --options=runtime --entitlements editor.entitlements -s ${OSX_KEY_ID} -v Godot.app/Contents/MacOS/Godot && \ zip -r ${binname}_signed.zip Godot.app" request_uuid=$(ssh "${OSX_HOST}" "xcrun altool --notarize-app --primary-bundle-id \"${OSX_BUNDLE_ID}\" --username \"${APPLE_ID}\" --password \"${APPLE_ID_PASSWORD}\" --file ${osx_tmpdir}/${binname}_signed.zip")