最近谷歌和英特尔已经发布了一种新的方式来运行模拟器,这应该比以前的版本(已经模拟ARM CPU)更好。这里有一些关于它的链接:这个和这个。

但是,在安装新组件并按照指示创建新的模拟器配置之后,我得到一个错误,也看不到任何改进。我已经尝试了API 10和API 15, GPU启用和禁用。这些配置都没有帮助。我也在两台不同的电脑上尝试过,没有任何提升(而且出现了同样的错误)。

似乎在我读过的帖子中,没有人有任何问题,所有人都报告了一个更快的模拟器。

它显示的错误是:

emulator: Failed to open the HAX device!
HAX is not working and emulator runs in emulation mode
emulator: Open HAX device failed

为什么会发生这种情况,有办法解决吗?还有其他人得到这些错误吗?反之亦然?

顺便说一下,我有一个英特尔的CPU,如果这有问题的话。


编辑:

这是我在BIOS中看到的,所以它应该是可用的…:

我想从命令行设置Android开发环境,遇到以下问题:

wget http://dl.google.com/android/android-sdk_r22.0.5-linux.tgz

解压完成后,运行

tools/android update sdk --no-ui

但是,它跑起来太慢了

Fetching https://dl-ssl.google.com/android/repository/addons_list-2.xml

结果是在文件夹build-tools中什么都没有,我想要的是apapt和apkbuilder,因为我想从命令行构建apk而没有ant。

我知道这是一个非常基本的问题,但令我惊讶的是,我找不到任何关于Android SDK构建工具的文档。 除了Android SDK Tools和Android SDK Platform-tools,还有一堆Android SDK Build-tools,如图所示。有没有人能指出一个来源来解释所有这些,并帮助澄清一个特定版本的Android SDK构建工具是如何被选择使用的?

编辑(2014-02-27):

我仍然没有完全理解所有的工具。以下是我根据谷歌最新的资料所作的有限了解:

Android SDK Build-tools used to be components of Android SDK Platform-tools. They have been decoupled from Android SDK Platform-tools, so that the build tools can be updated independently of the integrated development environment (IDE) components. Android SDK Platform-tools are customized to support the features of the latest Android platform. They are backward compatible so that you always use the latest update of Android SDK Platform-tools even your app targets older Android platforms. SDK tools are platform independent and are required no matter which Android platform you are developing on.

I still do not understand the rationale of taking Android SDK Build-tools out of Android SDK Platform-tools which has a single instance and is easy to manage the update. The only possible reason that I can think of is that some apps have to rely on older build components to build them. Google's document mentions this, but does not explain why. Looking at the release notes, you will notice that updates of Android SDK Build-tools are primarily for fixing bugs or/add support for new platforms. The only reason that I can think of for some apps to use older versions of Android SDK Build-tools is that they rely on certain bugs of Android SDK Build-tools. These apps would not function normally without being built with these bugs. I wish Google could explain this better by giving one or two examples showing why these bugs in the tools are critical for certain apps.

由于最近Oracle Java SE支持路线图策略更新(特别是在2019年3月之后结束Oracle的免费发布更新),我一直在寻找Oracle Java的替代品。我发现OpenJDK是一个开源的替代品。我还找到了AdoptOpenJDK(现在称为Adoptium),这是一个预构建的二进制文件。这谜题。

OpenJDK和Adoptium/AdoptOpenJDK有什么区别?

我有相当多的控件分散在我的表格中的许多表格单元格中,我想知道是否有一种更简单的方法来消除键盘,而不必循环遍历所有的控件并将它们全部辞职为第一响应器。我想问题是…我如何得到当前的第一个响应器的键盘?

我想将Android Studio中的最小SDK版本从API 12更改为API 14。我尝试在manifest文件中更改它,即,

<uses-sdk
    android:minSdkVersion="14"
    android:targetSdkVersion="18" />

和重建项目,但我仍然得到Android Studio IDE抛出一些错误。我假设我必须在“项目属性”或类似的东西中设置最小SDK,以便IDE识别变化,但我找不到这是在Android Studio中完成的。

因为gradle android插件2.2-alpha4:

Gradle会尝试下载项目中缺失的SDK包 取决于

这非常酷,是杰克·沃顿的一个项目。

但是,要下载SDK库,你需要:接受许可协议,否则gradle会告诉你:

您还没有接受以下SDK的许可协议 组件:[Android SDK Build-Tools 24, Android SDK Platform 24]。 在构建项目之前,您需要接受许可证 协议并完成缺少组件的安装 使用Android Studio SDK管理器。或者,学习如何 将许可证协议从一个工作站转移到另一个工作站,转到 http://d.android.com/r/studio-ui/export-licenses.html

这是一个问题,因为我想在做gradle构建时安装所有的sdk依赖。

我正在寻找一个解决方案,自动接受所有的许可证。也许是一个gradle脚本? 你有什么想法吗?

我已经看了用Gradle构建的文档,但我仍然不确定compileSdkVersion和targetSdkVersion之间的区别是什么。

它只是说:

The `compileSdkVersion` property specifies the compilation target.

那么,什么是“编译目标”呢?

我认为有两种可能的解释:

compileSdkVersion是构建应用程序时使用的编译器版本,而targetSdkVersion是“应用程序目标的API级别”。(如果是这种情况,我假设compileSdkVersion必须大于或等于targetSdkVersion? 它们是同一个意思。"编译目标" == "应用程序目标的API级别" 别的吗?

我知道这个问题以前被问过,但唯一的答案只是引用了文档,这对我来说是不清楚的。

我正在尝试在我的Windows 7 x64系统上安装Android SDK。

安装了JDK -6u23-windows-x64.exe,但Android SDK安装程序拒绝继续,因为它没有找到JDK安装。

这是已知的问题吗?有解决办法吗?