Eclipse项目没有无益的错误构建

时间:2013-09-25 14:47:35

标签: eclipse

Eclipse正在给我一个关于项目的红色X.我将此项目与另一个工作区中的类似项目进行了比较。类路径是不同的(它应该是),以及一些应该是的源文件。但问题标签中的错误是

“该项目不是由于”“而构建的。修复问题,然后尝试刷新此项目并构建它,因为它可能不一致”

是的,看似关键信息的那个关键点只会说“”。我尝试刷新和重建无济于事。项目从工作区外部导入。但这应该不重要,不是吗?我之前没有遇到任何问题。但是类似的项目(我正在比较的项目)在工作区中工作正常。

我还能在哪里查找可能有助于缩小范围的错误信息?

update - 此项目被其他人用作项目参考,但此项目不依赖于其他项目。这是它的类路径文件内容:

    <classpath>
    <classpathentry kind="src" path="src"/>
    <classpathentry kind="src" path="test"/>
    <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
    <classpathentry kind="con" path="org.eclipse.jst.server.core.container/com.ibm.ws.ast.st.runtime.runtimeTarget.v70/was.base.v7">
        <attributes>
            <attribute name="owner.project.facets" value="jst.utility"/>
        </attributes>
    </classpathentry>
    <classpathentry kind="src" path=".apt_generated">
        <attributes>
            <attribute name="optional" value="true"/>
        </attributes>
    </classpathentry>
    <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/WebSphere Application Server v7.0 JRE">
        <attributes>
            <attribute name="owner.project.facets" value="java"/>
        </attributes>
    </classpathentry>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/antlr-2.7.6.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/aspectjweaver-1.6.8.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/cecore.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/celib.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/ceplugins_client.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/ceplugins_core.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/ceplugins_cr.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/cereports.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/cesession.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/ceutils.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/cglib-nodep-2.2.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/aopalliance-1.0.0.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/apache-commons/commons-beanutils.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/apache-commons/commons-collections-3.2.1.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/apache-commons/commons-lang-2.4.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/apache-commons/commons-logging-1.1.1.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/corbaidl.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/dom4j-1.6.1.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/ebus405.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/hibernate/hibernate-3.5.1/hibernate3.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/icu4j-3.4.4.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/jasypt-1.7.1.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/javassist-3.9.0.GA.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/joda-time-1.6.1.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/jpa-api-2.0-cr-1.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/junit-4.8.2.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/log4j-1.2.5.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/buisnessObjects/logging.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.aop-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.asm-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.aspects-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.beans-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.context.support-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.context-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.core-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.expression-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.instrument.tomcat-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.instrument-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.jdbc-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.jms-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.orm-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.oxm-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.test-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.transaction-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.web.portlet-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.web.servlet-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.web.struts-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/spring/spring-framework-3.0.1/org.springframework.web-3.0.1.RELEASE-A.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/poi-3.7-beta3-20100924.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/serialization.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/SL_plugins.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/slf4j-api-1.5.8.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/misc3rdParty/slf4j-log4j12-1.5.8.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-auth-roles-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-datetime-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-devutils-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-extensions-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-guice-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-ioc-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-jmx-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-objectsizeof-agent-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-spring-1.4.7.jar"/>
    <classpathentry kind="lib" path="C:/views/SharedComp_Development/SharedComp_Software/jar/wicket/wicket-1.4.7/wicket-velocity-1.4.7.jar"/>
    <classpathentry kind="output" path="bin"/>
</classpath>

2 个答案:

答案 0 :(得分:0)

听起来项目已定义了依赖项,但项目名称已被删除。这可以通过手动编辑.classpath文件来完成。我会尝试从.classpath文件中删除所有依赖项目。

您可以通过编辑构建路径并删除任何项目从Eclipse执行此操作。然后添加依赖项目。这应该清理.classpath文件。

答案 1 :(得分:0)

感谢Zagrev提供的帮助,但事实证明,有人将我们的bin文件夹检查到我们的集成源代码控制中,因此eclipse实际上无法编译代码。一旦我删除了bin并且它可以生成,它就生成了很好并且错误消失了。

仍然,有点无益的消息。如果消息指向我不可写的类文件,我可能已经立即找到它。相反,我挣扎了好几个小时试图找出我的.classpath或.settings出了什么问题。