在Mac上找不到Android aapt

时间:2012-07-04 13:34:10

标签: android macos intellij-idea

尝试在MacOSX上的IntelliJ(v11.1)中编译我的android项目时出现以下错误。


I/O error: Cannot run program "/%PATH_TO_SDK%/android-sdk-macosx/platforms
/android-16/tools/aapt": error=2, No such file or directory

<小时/> 有些地方说我在使用32位时可能会使用64位版本的库,但遇到这个问题的每个人都在使用Ubuntu,所以我找到的解决方案只适用于此。

奇怪的是,今天早上我只安装了android-16,但是在我下载其他版本之后就停止了。

任何帮助将不胜感激。如果需要,可以提供更多信息。

2 个答案:

答案 0 :(得分:13)

aapt位置已更改,可在

找到
/path/to/adt/sdk/buid-tools/android-[version]/aapt

rafalmanka

更多信息:aapt not found under the right path

答案 1 :(得分:2)

在具有默认Android安装的MacOS High Sierra上,当前aapt位置位于特定的构建工具版本内。对于构建工具28.0.3,您可以在以下路径中找到它:

/Users/userName/library/Android/sdk/build-tools/28.0.3

在MacOS中,请记住将userName更改为您的用户名。