CI: Explicitly enable audio access on macOS 14

On the macOS 14 runners on GitHub actions, attempting to play audio (by
way of AudioOutputUnitStart) will open a pop-up asking for microphone
permission. This prevents any calling test to hang until they error out
with MACH_SEND_TIMED_OUT. This works around the issue by explicitly
enabling microphone access to all applications.
This commit is contained in:
Timothy Flynn 2024-05-08 11:44:41 -04:00 committed by Andrew Kaster
parent b9210a757e
commit a447b9bffd
Notes: sideshowbarker 2024-07-17 10:31:19 +09:00

View File

@ -65,6 +65,11 @@ jobs:
echo "host_cxx=$(brew --prefix llvm@18)/bin/clang++" >> "$GITHUB_OUTPUT"
fi
# https://github.com/actions/runner-images/issues/9330
- name: Allow microphone access to all apps (macOS 14)
run: sqlite3 $HOME/Library/Application\ Support/com.apple.TCC/TCC.db "INSERT OR IGNORE INTO access VALUES ('kTCCServiceMicrophone','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159,NULL,NULL,'UNUSED',1687786159);"
if: ${{ matrix.os == 'macos-14' }}
- name: Create Build Environment
working-directory: ${{ github.workspace }}/Meta/Lagom
run: |