gpt4 book ai didi

android - 在 meteor 的 Android 模拟器上启动应用程序永远不会完成

转载 作者:太空狗 更新时间:2023-10-29 13:55:36 28 4
gpt4 key购买 nike

今天我想测试 Meteor 的 android build 是如何工作的。所以我安装了 Meteor 并根据 their instructions 创建了一个测试待办应用程序.然后公关。使用说明 from here我安装了 Java SDK,并确认我在安装 Visual Studio 2015 时拥有 Android SDK。

然后我的第一个问题来了。当我尝试从命令提示符运行 meteor add-platform android 时。我收到错误找不到模块“is-property”,并很快学会了通过 cd 到缺少模块的目录并运行 npm install is-property 来修复此问题. A hat tip to this thread for the solution .

好的,再来一次:meteor add-platform android 这次成功了。然后我运行了 meteor run android,果然,我的应用程序启动了一个模拟器。或者差不多。因为迎接我的第一条消息是应用程序错误 - 与服务器的连接不成功 (http://localhost:12784),应用程序崩溃了。

经过一番搜索,似乎是因为模拟器太慢了, meteor 脚本超时导致了崩溃。所以我然后尝试安装 Android Studio使用 Android AVD manager .但现在模拟器甚至无法启动,我得到了以下信息:

enter image description here

在 android 模拟器上启动应用程序 然后...什么都没有。

所以我尝试卸载所有的android sdks、android studio和meteor。

然后我尝试

  1. 再次安装 meteor 。
  2. 仅安装 Android SDK命令行工具。
  3. Added the Android SDK to my environment variables .
  4. 运行 android.bat 以确保我安装了几乎所有最新的工具和图像以及 Intel x86 仿真器加速器(HAXM 安装程序) List item
  5. 然后我尝试再次运行 meteor run android 命令,结果卡在了在 android 模拟器上启动应用,如第一张图片所示。
  6. Android 模拟器上的启动应用运行一个多小时,看看是否运行缓慢。

我还尝试在没有帮助的情况下遵循以下资源的建议:

顺便说一下,这是我的 AVD 配置的样子

enter image description here

那我做错了什么? 一切 都不会是一个令人惊讶的答案。开个玩笑,我需要做什么才能让我的 meteor 应用程序在 Windows 10 上正常运行 android 模拟器?

最佳答案

我得到了完全相同的结果,但我终于找到了问题所在。

我尝试从命令行运行模拟器:

emulator -avd Android_Emulator

这实际上给了我一个有用的错误信息:

emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure Intel HAXM is properly installed and usable.
CPU acceleration status: HAXM is not installed on this machine

这个 StackOverflow 线程帮助弄清楚了如何安装它:Intel X86 emulator accelerator (HAXM installer) VT/NX not enabled

然后成功了!真的真的很慢!但它奏效了。

关于android - 在 meteor 的 Android 模拟器上启动应用程序永远不会完成,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39965475/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com