为什么我的 Android 应用程序在真实设备上测试时无法运行?

Why isn't my Android app working when I test it on a real device?

我正在使用 Ionic Framework 构建一个 Android 应用程序,并尝试在具有 USB 调试功能的真实设备上 运行 它,就像在这些教程中一样:

http://www.neilberry.com/how-to-run-your-ionic-app-on-real-devices/?s=2015-08-24-how-to-run-your-ionic-app-on-real-devices

http://junerockwell.com/how-to-run-ionic-on-real-devices/

第一步

$ ionic platform add android

$ ionic build android

添加 Android 平台并使用上述命令构建 APK 后,它可以正常运行,没有错误。所以,我尝试下一步:

第 2 步

我通过调试模式将设备和 PC 连接到 运行 android 台设备。我运行命令ionic run android。我收到以下错误消息 L

$ ionic run android

ANDROID_HOME=C:\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_25 WARNING : No target specified, deploying to emulator WARNING : no emulator specified, defaulting to Nexus_5_API_23_x86 Waiting for emulator... emulator: ERROR: x86 emulation currently requires hardware acceleration! Please ensure Intel HAXM is properly installed and usable. CPU acceleration status: HAX kernel module is not installed!

我该如何解决这个问题?

我的离子信息列表:

$ ionic info

Your system information: Cordova CLI: 5.4.1 Gulp version: CLI version 3.9.0 Gulp local: Local version 3.9.0 Ionic Version: 1.2.4 Ionic CLI Version: 1.7.13 Ionic App Lib Version: 0.6.5 OS: Windows 8.1 Node Version: v4.2.4

我不用ionic,我用cordova。在 cordova 中,您可以通过以下方式调用模拟器:

cordova emulate android 

并 运行 设备上的应用程序:

cordova run android --device

也许你试试:

ionic run android --device

也许你可以试试 运行 adb start-server。我知道我需要先执行此操作才能在 chrome://inspect/#devices 中看到我的设备。您当然需要 adb,它可能来自 Android SDK。

此错误与 ionic frameworks 无关,因为 HAXM installer 未安装在 Android SDK 管理器.[=13= 上]

This question already has an answer here: Error in launching AVD with AMD processor.