Specify ADB_SERIAL for emulator

This commit is contained in:
topjohnwu 2025-04-13 21:43:11 -07:00
parent cb08504fe5
commit c1e061603b
2 changed files with 5 additions and 2 deletions

View File

@ -3,7 +3,10 @@
set -xe
. scripts/test_common.sh
emu_args_base="-no-window -no-audio -no-boot-anim -gpu swiftshader_indirect -read-only -no-snapshot -cores $core_count"
emu_port=5682
export ANDROID_SERIAL="emulator-$emu_port"
emu_args_base="-no-window -no-audio -no-boot-anim -gpu swiftshader_indirect -read-only -no-snapshot -port $emu_port -cores $core_count"
emu_pid=
atd_min_api=30

View File

@ -12,7 +12,7 @@ emu="$ANDROID_HOME/emulator/emulator"
sdk="$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager"
avd="$ANDROID_HOME/cmdline-tools/latest/bin/avdmanager"
boot_timeout=600
boot_timeout=100
core_count=$(nproc)
if [ $core_count -gt 8 ]; then