java - Could not find dependencies for aspectj-maven-plugin -
i have problem ctw aspects using aspectj-maven-plugin. following error (execution entry being highlighted):
multiple annotations found @ line: - execution default of goal org.codehaus.mojo:aspectj-maven-plugin:1.5:compile failed: plugin org.codehaus.mojo:aspectj-maven-plugin:1.5 or 1 of dependencies not resolved: not find artifact com.sun:tools:jar:1.7.0_21 @ specified path c:\program files\java\jre7/../lib/tools.jar (org.codehaus.mojo:aspectj-maven- plugin:1.5:compile:default:compile) - execution default of goal org.codehaus.mojo:aspectj-maven-plugin:1.5:test-compile failed: plugin org.codehaus.mojo:aspectj-maven-plugin:1.5 or 1 of dependencies not resolved: not find artifact com.sun:tools:jar:1.7.0_21 @ specified path c:\program files\java\jre7/../lib/tools.jar (org.codehaus.mojo:aspectj-maven- plugin:1.5:test-compile:default:test-compile)
on configuration:
<build> <plugins> <!-- http://mojo.codehaus.org/aspectj-maven-plugin/usage.html --> <plugin> <groupid>org.codehaus.mojo</groupid> <artifactid>aspectj-maven-plugin</artifactid> <version>1.5</version> <configuration> <showweaveinfo>true</showweaveinfo> <outxml>true</outxml> <source>1.7</source> <target>1.7</target> <sources> <source> <basedir>src/main/java</basedir> <includes> <include>**/*aspect.java</include> </includes> </source> </sources> </configuration> <executions> <execution> <goals> <goal>compile</goal> <goal>test-compile</goal> </goals> </execution> </executions> </plugin> </plugins> </build>
what doing wrong? looks if plugin unable find jdk? why?
is java_home
set properly? please check that. worked me. think should add below mentioned plugin , try:
<plugin> <groupid>org.apache.maven.plugins</groupid> <artifactid>maven-compiler-plugin</artifactid> <version>2.3.2</version> <configuration> <source>1.6</source> <target>1.6</target> </configuration> </plugin>
run mvn compile
after that.
Comments
Post a Comment