我正在尝试将.apk安装到AVD,但该过程只会挂起消息- waiting for device -
。
这是我如何启动模拟器并连接到它:
$ /opt/android-sdk-linux/tools/emulator-arm -no-boot-anim -ports 5851,5852 -prop persist.sys.language=en -prop persist.sys.country=US -avd hudson_en-US_160_WVGA_android-22_armeabi-v7a_myapp -no-snapshot-load -no-snapshot-save -no-window -force-32bit -noaudio -gpu off
Failed to Initialize backend EGL display
$ /opt/android-sdk-linux/platform-tools/adb connect emulator-5851
[android] Waiting for emulator to finish booting...
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5851 shell getprop init.svc.bootanim
error: device offline
$ /opt/android-sdk-linux/platform-tools/adb connect localhost:5851
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5851 shell getprop init.svc.bootanim
error: device offline
$ /opt/android-sdk-linux/platform-tools/adb connect localhost:5851
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5851 shell getprop init.svc.bootanim
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5851 logcat -v time
[android] Attempting to unlock emulator screen
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5851 shell input keyevent 82
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5851 shell input keyevent 4
[android] Emulator is ready for use (took 47 seconds)
/opt/android-sdk-linux/platform-tools/adb connect emulator-5851
$ /opt/android-sdk-linux/platform-tools/adb -s emulator-5584 install -r myapp-debug-unaligned.apk
error: device not found
- waiting for device -
当我尝试为较旧的Android版本运行AVD时,它运行正常。