如何诊断"错误执行AAPT"在Eclipse中的错误? [英] How to diagnose "Error executing aapt" error in Eclipse?

查看:202
本文介绍了如何诊断"错误执行AAPT"在Eclipse中的错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经准备好撕我的头发,因为我无法得到它认为它无法找到AAPT的状态Eclipse的脱胶:

I'm ready to tear my hair out because I can't get Eclipse unstuck from a state where it thinks it can't find aapt:

Error executing aapt. Please check aapt is present at /usr/local/android-sdk-linux_x86/platform-tools/aapt

我发现了一堆帖子关于这个问题,它建议删除错误在Eclipse的用户界面,删除R.java,重建项目,重新启动Eclipse的,等这些东西有助于暂时的,但只要我编辑一个XML文件,Eclipse将被再次borked。它变得非常讨厌,重建我的所有源和重新启动Eclipse我每次更改的XML文件。

I've found a bunch of posts on this subject, which suggest deleting the error in the Eclipse UI, deleting R.java, rebuilding the project, restarting Eclipse, etc. These things help temporarily, but as soon as I edit an XML file, Eclipse gets borked again. It's getting really annoying to rebuild all my source and restart Eclipse every time I change an XML file.

AAPT显然是有:

$ ls -l /usr/local/android-sdk-linux_x86/platform-tools/aapt
-rwxr-xr-x 1 boris boris 3764858 2011-07-28 11:50 /usr/local/android-sdk-linux_x86/platform-tools/aapt

有没有办法知道到底是什么错误是真实发生的?我试图寻找在Eclipse控制台输出和.metadata / .log文件在我的项目,并没有看到任何相关的。

Is there a way to know exactly what the error is that's occurring? I tried looking in the Eclipse console output and in .metadata/.log in my project and didn't see anything related.

推荐答案

打这个今天再次,发现从AAPT详细的输出并没有帮助。它只是吐出来的是AAPT命令控制台和失败,没有错误。

Hit this again today, and discovered that verbose output from aapt doesn't help. It just spits out the aapt command to the console and fails without an error.

我想我终于读懂了什么地方出了错底部。我相信,AAPT未能由于内存不足。我的Eclipse过程中使用的内存1.2GB。当Eclipse运行AAPT,它派生的过程当中,从我的理解,中分配的另一个的1.2GB只是为了运行AAPT。

I think I've finally gotten to the bottom of what's going wrong. I believe that aapt is failing due to insufficient memory. My Eclipse process was using 1.2GB of memory. When Eclipse runs aapt, it forks the process which, from what I understand, allocates another 1.2GB just for running aapt.

我看了看我的进程列表,看到Firefox的使用几乎400MB的内存。我杀了火狐,然后AAPT开始工作。疯了。

I looked at my process list, and saw that Firefox was using almost 400MB of memory. I killed Firefox, and then aapt started working. Crazy.

这篇关于如何诊断"错误执行AAPT"在Eclipse中的错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆