为什么 CDT 在 Ant 上重建我的 C 项目并在不相关的项目中构建?
我有一个 Eclipse 工作区,其中 CDT 项目与其他不相关的项目共存。然而,当我在其中一个项目中运行“build as Ant build”时,CDT 也坚持重建其项目。
任何人都知道如何断开这种“隐藏”依赖关系? (不,它不在“链接资源”或“项目参考”中......)
I have an Eclipse workspace where a CDT project lives together with other unrelated projects. However, when I run "build as Ant build" in one of those projects, CDT insists on rebuilding its projects too.
Anyone have any ideas where to look to disconnect this "hidden" dependency? (And no, it's not in the "Linked Resources" or the "Project References"...)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
工作区范围的构建实际上是由于我未能在“外部工具配置”中找到构建的选项造成的。您可以在此处指定构建整个工作区、包含的项目或某些特定资源。
还有一个 Eclipse bug,用于将默认值设置为不同于构建整个工作空间。 (人们可能会认为“Run as Ant build”默认不会构建任何东西,除了运行指定的 Ant 目标。)
The workspace wide build was actually caused by me failing to find the option for the build in "External Tools Configurations". There you can specify to build the whole workspace, the containing project, or some specific resource.
There is also an Eclipse bug for setting the default to something different than to build the whole workspace. (One could think that "Run as Ant build" would default to not build anything except running the specified Ant target.)
项目构建器是根据某些构建触发器的请求运行的。这可能是资源更改(当您自动启用构建时),也可能是您正在使用的构建操作:“构建为 Ant 构建”。构建操作可能会无意中请求构建整个工作区。
将以下内容放入文本文件中:
并使用附加开关运行 Eclipse:
这会将跟踪打印回显到启动 Eclipse 的 shell。您可以使用它来更好地定位您无疑会提交的错误报告:)
Project builders are run at the request of some build trigger. This might be resource changes (when you have build automatically enabled) or it could be the build action you're using: "build as Ant build". The build action may be inadvertently requesting a build of the whole workspace.
Put the following in a text file:
And run Eclipse with the additional switches:
This will echo trace prints to the shell in which you started Eclipse. You can use this to better target the bug report you'll no doubt file :)
尝试取消选中
项目
菜单下的自动构建
复选框。Try to uncheck the
Build Automatically
checkbox, underProject
menu.