2023-09-10 04:25:36 +02:00
|
|
|
#!/usr/bin/env bash
|
2023-03-02 18:33:29 +01:00
|
|
|
#
|
|
|
|
# SPDX-FileCopyrightText: 2023 The Calyx Institute
|
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
#
|
2023-09-10 04:25:36 +02:00
|
|
|
|
|
|
|
# assert ANDROID_HOME is set
|
2023-09-22 06:12:53 +02:00
|
|
|
if [ -z "$ANDROID_HOME" ]; then
|
|
|
|
echo "ANDROID_HOME is not set"
|
2023-09-10 04:25:36 +02:00
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
# assert 1 parameter is provided
|
|
|
|
if [ $# -ne 1 ]; then
|
|
|
|
echo "Usage: $0 <emulator_name>"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
EMULATOR_NAME=$1
|
|
|
|
|
|
|
|
echo "Starting emulator..."
|
2023-10-08 20:16:53 +02:00
|
|
|
nohup $ANDROID_HOME/emulator/emulator -avd "$EMULATOR_NAME" -gpu swiftshader_indirect -writable-system >/dev/null 2>&1 &
|