Move toolsjar config to pre-jigsaw profile.
Cause there is no tools.jar in Java 9+ and this breaks the build if
invoked with Java 11.
Change-Id: I4f28d1347f6473aa7482758e852eeaf34816b3ac
Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>
diff --git a/bundles/binaries-parent/pom.xml b/bundles/binaries-parent/pom.xml
index 679fb2d..ed90642 100644
--- a/bundles/binaries-parent/pom.xml
+++ b/bundles/binaries-parent/pom.xml
@@ -77,13 +77,6 @@
</executions>
<dependencies>
<dependency>
- <groupId>com.sun</groupId>
- <artifactId>tools</artifactId>
- <version>0.0.0</version>
- <scope>system</scope>
- <systemPath>${toolsjar}</systemPath>
- </dependency>
- <dependency>
<groupId>org.mozilla</groupId>
<artifactId>rhino</artifactId>
<version>1.7.10</version>
@@ -97,4 +90,29 @@
</plugin>
</plugins>
</build>
+ <profiles>
+ <profile>
+ <id>pre-jigsaw</id>
+ <activation>
+ <jdk>1.8</jdk>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <dependencies>
+ <dependency>
+ <groupId>com.sun</groupId>
+ <artifactId>tools</artifactId>
+ <version>0.0.0</version>
+ <scope>system</scope>
+ <systemPath>${toolsjar}</systemPath>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+
+</profiles>
</project>