Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Project build breaks from recursive "target/classes" directory(Eclipse is building recursive target class directories)
Project build breaks from recursive "target/classes" directory [message #1750981] Tue, 03 January 2017 11:55 Go to next message
Todd Shore is currently offline Todd ShoreFriend
Messages: 2
Registered: January 2017
Junior Member
I'm trying to build a basic Java Eclipse project derived from a Maven POM, which has a single other Eclipse project in the same workspace as a dependency. However (for as yet unknown reasons), the project can no longer be built, with the following error marker:

Quote:
The project was not built due to "Could not delete '/tangrams/target/classes/target'.". Fix the problem, then try refreshing this project and building it since it may be inconsistent


When I examine the $PROJECT\target directory, it in fact seems to be made of (nearly-)infinite recursive target\classes subdirectories, e.g. target\classes\target\classes\target\classes\target\classes; What is going on here?

Moreover, if I try to delete the $PROJECT\target directory using the Windows explorer, I get the following error message:

Quote:
Could not find this item

This is no longer located in ...
Verify the item's location and try again.


Environment


  • Windows 10 Pro 64-bit
  • Eclipse JEE Neon.1a Release (4.6.1), Build id: 20161007-1200
  • Maven runtime 3.3.9/1.7.0.20160603-1931 embedded in Eclipse
  • JDK 1.8.0_112 (64-bit)

Re: Project build breaks from recursive "target/classes" directory [message #1751043 is a reply to message #1750981] Tue, 03 January 2017 21:01 Go to previous messageGo to next message
Stephan Herrmann is currently offline Stephan HerrmannFriend
Messages: 1853
Registered: July 2009
Senior Member
Sounds like you managed to define the project root as a source folder, which then gets copied into target/classes (including the contained target directory of course).
Have a look at your build path (or file .classpath).

For details of how import from maven configured the project please ask on the m2e mailing list (or file a bug against m2e if you are sure there's a bug).

Stephan
Re: Project build breaks from recursive "target/classes" directory [message #1751075 is a reply to message #1751043] Wed, 04 January 2017 10:09 Go to previous messageGo to next message
Todd Shore is currently offline Todd ShoreFriend
Messages: 2
Registered: January 2017
Junior Member
Quote:
Sounds like you managed to define the project root as a source folder, which then gets copied into target/classes (including the contained target directory of course).
Have a look at your build path (or file .classpath).


Unfortunately this is not the case, as the classpath looks extremely straightforward, mirroring the extremely basic POM:

<classpath>
	<classpathentry kind="src" output="target/classes" path="src/main/java">
		<attributes>
			<attribute name="optional" value="true"/>
			<attribute name="maven.pomderived" value="true"/>
		</attributes>
	</classpathentry>
	<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources">
		<attributes>
			<attribute name="maven.pomderived" value="true"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="src" output="target/test-classes" path="src/test/java">
		<attributes>
			<attribute name="optional" value="true"/>
			<attribute name="maven.pomderived" value="true"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
		<attributes>
			<attribute name="maven.pomderived" value="true"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
		<attributes>
			<attribute name="maven.pomderived" value="true"/>
		</attributes>
	</classpathentry>
	<classpathentry combineaccessrules="false" kind="src" path="/IrisTK"/>
	<classpathentry kind="output" path="target/classes"/>
</classpath>


I do not know what is happening and unfortunately I can't even find the condition which reproduces the problem each time: Today, for example, the problem is not there any more.
Re: Project build breaks from recursive "target/classes" directory [message #1751086 is a reply to message #1751075] Wed, 04 January 2017 11:47 Go to previous message
Stephan Herrmann is currently offline Stephan HerrmannFriend
Messages: 1853
Registered: July 2009
Senior Member
	<classpathentry combineaccessrules="false" kind="src" path="/IrisTK"/>


What is "/IrisTK"? If that's a project shouldn't it be 'kind="prj"'??
Previous Topic:Keyboard Input and Live Text Animation Help
Next Topic:groovy script - create Hashmap as global variable
Goto Forum:
  


Current Time: Thu Apr 18 01:24:05 GMT 2024

Powered by FUDForum. Page generated in 0.02200 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top