为什么我更新的Eclipse / Android设置不再建立我的APK了? [英] Why is my updated Eclipse / Android setup not building my APK anymore?

查看:156
本文介绍了为什么我更新的Eclipse / Android设置不再建立我的APK了?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个工作的Eclipse安装程序3.6.2和SDK工具从版本11,并已经建立我的主要项目很好一段时间。

I had a working Eclipse setup with 3.6.2 and SDK tools from version 11, and it has been building my main project just fine for quite a while.

对于不同的项目,我认为我需要升级我的SDK到最新和最伟大的 - 在这一点API 14(ICS 4.0)。

For a different project, I thought I needed to upgrade my SDK to the latest and greatest - at this point API 14 (ICS 4.0).

我甚至不能重建步骤我经历了,但是发生了什么事情是我的项目似乎构建了,但是我会看到它会跳过一个后编译器,最后我将没有APK。

I cannot even reconstruct the steps I went through, but what happened was that my project would seem to build, but I would see that it would say that it was skipping a post-compiler step, and at the end I would have no APK.

我也注意到它更新了我的.classpath,以便输出路径是bin / classes而不是.bin。

I also noticed that it updated my .classpath so that the output path was bin/classes instead of .bin.

我尝试将Eclipse更新到最新版本(Indigo 3.7.1),但这没有帮助。

Along the way I tried updating my Eclipse to the latest version (Indigo 3.7.1) but this didn't help.

推荐答案

我解决了问题最终在Google Android论坛上的这篇文章中有帮助:

I solved the problem eventually with help from this post on the Google Android forum:

http://code.google.com/p/android/issues/detail?id=21031

对我个人而言最大的问题似乎解决了如下(在论坛帖子中的评论25的qutoe)
我似乎解决了.apk文件没有被自动构建,直到使用运行/调试(注释#10,#11等) )。转到Windows - >首选项 - > Android - >构建并取消选中跳过打包和导出直到导出或启动,然后重新启动Eclipse。对于我来说,这是有用的。

For me personally the biggest issue seemed to be solved as follows (qutoe from comment 25 in the forum post) "I seem to solve the problem with .apk files not being built automatically until run/debug is used (comments #10, #11 etc.). Go to Windows -> Preferences -> Android -> Build and uncheck "Skip packaging and dexing until export or launch" then restart Eclipse. Works for me."

但是还有其他有用的东西,不同的项目似乎有不同的问题。

But there is other useful material there. Different people with different projects seem to have different problems with this setup.

我仍然不明白类路径的变化,但似乎并不重要。

I still don't understand the change in the classpath, but it doesn't seem to matter.

此外,我发现了一个讨论使用Eclipse Indigo安装ADT,这在Stackoverflow中有帮助:

In addition, I found a discussion of installing the ADT with Eclipse Indigo which was helpful here in Stackoverflow:

Eclipse Indigo - 无法安装Android ADT插件

我也发现我想是因为各种卸载/重新安装由于某种原因,它停止从源代码中排除我的.svn目录。这个Stackoverflow文章对此有帮助:

I also found that I guess because of various uninstalls/reinstalls, for some reason it stopped excluding my .svn directories from the sources. This Stackoverflow post was helpful with that:

为什么eclipse试图复制我的。 svn文件夹从src到bin,我该如何停止?

最后:真正卸载Eclipse的提示 - 每个人都说没有卸载,而且还有不过,有一个Eclipse在您的主目录(位于c:\users\之下的Windows 7中)中的目录,名为.eclipse -
如果您真的想要开始新建,请将其删除。

Finally: a tip for really and truly uninstalling Eclipse - everybody says there is no uninstall, and there isn't, but there is a directory that Eclipse leaves in your home directory (in windows 7 under c:\users\) called .eclipse - Zap it if you really want to start fresh.

此外,对于较不极端的措施,Eclipse中还有Project-> Clean,您可以使用eclipse -clean调用eclipse来获得更多清洁效果。不知道是什么,但是沿途的各种有益的人建议尝试解决问题。

In addition, for less extreme measures, there is Project->Clean inside Eclipse, and you can invoke eclipse with "eclipse -clean" for additional cleansing effects. No idea what, but various helpful people along the way suggested trying that to solve problems.

是的 - 当我第一次安装靛蓝并尝试构建时,我收到了一个警告我的Java编译器合规级别没有达到鼻烟,这根本不是真的 - 我的机器上只安装了Java 1.6。
对于有类似经历的人,请看这篇文章:

Ah yes - when I first installed Indigo and tried to build, I got a warning that my Java Compiler Compliance level was not up to snuff, which was simply not true - I have only Java 1.6 installed on my machine. See this post for somebody who had similar experience:

http://marakana.com/forums/android/general/374.html

对我来说,什么工作只是去Project,Properties,Java Compiler,然后点击Configure Workspace Settings,然后在对话框中点击Ok。不需要改变任何东西。只是显示它一切都OK!

For me, what worked was simply going to Project, Properties, Java Compiler, then click on Configure Workspace Settings, and click on Ok in the dialog. Didn't need to actually change anything. Just showed it that everything was ok!

最终我确实清理了我的Eclipse和Android安装(包括上述.eclipse目录,还有一个.android目录如果卸载Android SDK Tools,您可能要删除的主目录不会这样做 - 实际上可以卸载它)。从头开始安装所有内容,然后使用上面提供的附加信息,现在它正在构建我的APK。

Eventually I indeed did clean out my Eclipse and Android installations (including the aforementioned .eclipse directory, and there's also an .android directory in your home directory which you may want to erase if uninstalling the Android SDK Tools doesn't do that - this actually is uninstallable). Installed everything from scratch and then used the additional information provided above and now it's building my APK.

我希望这可以节省一些我花了几个小时的时间来恢复我的构建。

I hope this saves somebody the hours I spent getting my build back in shape.

这篇关于为什么我更新的Eclipse / Android设置不再建立我的APK了?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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