-
Nov 26th, 2012, 09:02 AM
#1
Project weird behaviour (dependency thing)
Hi,
The Roo project I'm working on is behaving very weirdly for a few days. Everything was fine before and I can't think of an change explaining the new behaviour. Restoring to a previous commit doesn't change anything so it has somethingg to do with the environnement.
First I have the following error: "Syntax error, annotations are only available if source level is 1.5 or greater" on all annotations.
If I apply the quick fix "Change compliance to 1.5" and add "Maven dependencies" to web deployment assembly, I can deploy again. But I still have a red cross on the project.
If I do Maven/update project configuration I'm back at the beginning.
I've done a lot of manipulations (project import, repository reset...) since this morning and went into very different stages but nothing solved this very unstable situation.
Can you help me please?
Thank you
-
Nov 26th, 2012, 09:25 AM
#2
Open the pom, add a build plugin (the maven-compiler-plugin) and set the correct source/target version you want to use. The default compiler setting is to use 1.4. (I would expect that Roo already added this but you might have changed it).
-
Nov 26th, 2012, 09:44 AM
#3
it is there
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
</plugin>
But looking for the java.version value I realized that the Java compiler "Enable specific settings" was set. Unsetting it solved everything!
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules