coin: Give coin agent permission to access Bluetooth

The Qt Connectivity tests rely on this.

Pick-to: 6.8
Change-Id: I7218485e583ebe2c8d381a0104012a86350e6eac
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Aku Pietikäinen <aku.pietikainen@qt.io>
This commit is contained in:
Tor Arne Vestbø
2024-06-25 14:17:10 +02:00
parent 5a5567ecd1
commit 3ad98d0b27

View File

@@ -9,8 +9,16 @@ if touch "$TCC_DATABASE"; then
REQ_STR=$(codesign -d -r- "$BOOTSTRAP_AGENT" 2>&1 | awk -F ' => ' '/designated/{print $2}')
REQ_HEX=$(echo "$REQ_STR" | csreq -r- -b >(xxd -p | tr -d '\n'))
SERVICES=()
# Qt Multimedia tests need microphone access
SERVICES+=('kTCCServiceMicrophone')
# Qt Connectivity tests need Bluetooth access
SERVICES+=('kTCCServiceBluetoothAlways')
# shellcheck disable=SC2043
for service in kTCCServiceMicrophone; do
for service in "${SERVICES[@]}"; do
sqlite3 -echo "$TCC_DATABASE" <<EOF
DELETE from access WHERE client = '$BOOTSTRAP_AGENT' AND service = '$service';
INSERT INTO access (service, client, client_type, auth_value, auth_reason, auth_version, csreq, flags) VALUES (