【发布时间】:2019-10-03 10:54:34
【问题描述】:
我正在尝试在 Ubuntu 18.04 上设置 Android 模拟器。我已经设法让 Android Studio 运行起来。但是,它只能运行支持 ABI/CPU x86 的模拟器。如果我尝试使用用于 arm64 或 armeabi-v7a 的虚拟设备运行模拟器,模拟器就会冻结。这些是日志:
12:54 PM Emulator: statvfs('/home/pc/.android/avd/Pixel_2_API_25_32b.avd/snapshots/default_boot/ram.img') failed: No such file or directory
12:54 PM Emulator: Warning: QStandardPaths: XDG_RUNTIME_DIR points to non-existing path '/run/user/1000/snap.android-studio', please create it with 0700 permissions. ((null):0, (null))
12:54 PM Emulator: Warning: QXcbIntegration: Cannot create platform OpenGL context, neither GLX nor EGL are enabled ((null):0, (null))
12:54 PM Emulator: ERROR: Unable to access '/home/pc/.emulator_console_auth_token': emulator console will not work
12:54 PM Emulator: Warning: restoring GLES1 context from snapshot. App may need reloading.
12:54 PM Emulator: emulator: WARNING: IniFile.cpp:235: Failed to open .ini file /home/pc/.android/emu-update-last-check.ini for writing.
我需要这些配置,因为我要使用的 APK 不支持 x86 架构。
是否有人可能知道如何使具有这些规格的虚拟设备在适用于 Ubuntu 18 的 Android Studio 上运行,或者是否有其他方法可以运行不兼容 x86 的 APK?
为了让您全面了解,我想使用 Appium(或其他类似软件)进行自动化测试。因此,如果除了 Android Studio 之外还有另一种可靠的方式来运行 arm64 或 armeabi-v7a 仿真器,然后 Appium(或其他自动化软件)可以访问这些仿真器,那也很棒。我试过Anbox,但总是卡顿。
非常感谢!
【问题讨论】:
标签: android android-studio android-emulator ubuntu-18.04