I made a new struts project in eclipse using the struts2-archtype-starter.
A few errors where in my project already before doing anything. Solved most of them but th
You can't use tools.jar from a repository.
Sadly, something in your dependency tree thinks that you can. So, you have to use an 'excludes' to get rid of the existing dependency, and then replace it with the following.
If you make the version in the below match that in the error message, you might not need the 'excludes'.
You need:
<profiles>
<profile>
<id>default-tools.jar</id>
<activation>
<property>
<name>java.vendor</name>
<value>Sun Microsystems Inc.</value>
</property>
</activation>
<dependencies>
<dependency>
<groupId>com.sun</groupId>
<artifactId>tools</artifactId>
<version>whatever</version>
<scope>system</scope>
<systemPath>${java.home}/../lib/tools.jar</systemPath>
</dependency>
</dependencies>
</profile>
The Main Problem is that the mavan can not fine the tool.jar. so this problem occurs
u just add tool.jar file in your project .The Tool.jar present in you java software C:\Program Files\Java\jdk1.6.0_14\lib
try this code i hope you run successfully
http://maven.apache.org/xsd/maven-4.0.0.xsd">
4.0.0
Strust2Testing
Strust2Testing
0.0.1-SNAPSHOT
war
org.apache.struts
<artifactId>Struts2-core </artifactId>
<version>2.3.15.1</version>
<exclusions>
<exclusion>
<artifactId>tools</artifactId>
<groupId>com.sun</groupId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
<build>
<sourceDirectory>src</sourceDirectory>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<version>2.3</version>
<configuration>
<warSourceDirectory>WebContent</warSourceDirectory>
<failOnMissingWebXml>false</failOnMissingWebXml>
</configuration>
</plugin>
</plugins>
</build>
sudo apt-get install openjdk-7-source