In module 'ajdoc', our tests need tools.jar when running on JDK 8 in order to dynamically compile during runtime. Hence, dependency com.github.olivergondza:maven-jdk-tools-wrapper was re-added to the POM (with test scope this time) and Maven Dependency plugin configured to regard it as a used dependency and not falsely report it as unused. Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>tags/V1_9_7_M2
@@ -13,6 +13,21 @@ | |||
<packaging>jar</packaging> | |||
<name>ajdoc</name> | |||
<build> | |||
<plugins> | |||
<plugin> | |||
<groupId>org.apache.maven.plugins</groupId> | |||
<artifactId>maven-dependency-plugin</artifactId> | |||
<configuration> | |||
<usedDependencies> | |||
<!-- The tests need this during runtime, even though no direct usage is in our classes --> | |||
<usedDependency>com.github.olivergondza:maven-jdk-tools-wrapper</usedDependency> | |||
</usedDependencies> | |||
</configuration> | |||
</plugin> | |||
</plugins> | |||
</build> | |||
<dependencies> | |||
<dependency> | |||
<groupId>org.aspectj</groupId> | |||
@@ -34,6 +49,12 @@ | |||
<artifactId>org.aspectj.ajdt.core</artifactId> | |||
<version>${project.version}</version> | |||
</dependency> | |||
<dependency> | |||
<!-- enables easy dependency on tools.jar --> | |||
<groupId>com.github.olivergondza</groupId> | |||
<artifactId>maven-jdk-tools-wrapper</artifactId> | |||
<version>0.1</version> | |||
</dependency> | |||
<dependency> | |||
<groupId>org.aspectj</groupId> | |||
<artifactId>asm-renamed</artifactId> |
@@ -255,11 +255,16 @@ | |||
<!-- | |||
This plugin is nice to have in the POM, because then it is easy to double-click a goal such as 'analyze' or | |||
'tree' from a modern IDE in order to inspect dependency management in the project. | |||
Tip: If you want a quick overview, run this from the project from the project root directory: | |||
mvn -P \!create-docs dependency:analyze | grep -E '\[(WARNING|INFO\] -+< .+:.+ >-+)' > dependency-analyze.txt | |||
But be careful that all modules are actually listed - usually 'org.aspectj:installer' is the last one in the | |||
list. You can make sure by running the command without 'grep' first, then you see if there are any compile | |||
problems which 'grep' would filter out. | |||
--> | |||
<plugin> | |||
<groupId>org.apache.maven.plugins</groupId> | |||
<artifactId>maven-dependency-plugin</artifactId> | |||
<version>3.1.2</version> | |||
<configuration> | |||
<ignoredUnusedDeclaredDependencies> | |||
<!-- Declared in parent POM for convenience, but not used in every module --> |