Skip to content

Commit

Permalink
Remove toolchain for Java 8 and update maven compiler configuration f…
Browse files Browse the repository at this point in the history
…or integration tests to use Java 11
  • Loading branch information
josegar74 authored and fxprunayre committed Jun 26, 2023
1 parent a4db92a commit c1473f1
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 57 deletions.
4 changes: 2 additions & 2 deletions integration-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@
<version>3.8.1</version>
<configuration>
<encoding>UTF-8</encoding>
<source>1.8</source>
<target>1.8</target>
<source>11</source>
<target>11</target>
<compilerArgument>-Werror</compilerArgument>
</configuration>
</plugin>
Expand Down
31 changes: 0 additions & 31 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1368,37 +1368,6 @@
</plugins>
</build>
</profile>
<profile>
<!-- force use of java 8 if available in toolchains.xml -->
<id>toolchain</id>
<activation>
<file>
<exists>${user.home}/.m2/toolchains.xml</exists>
</file>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-toolchains-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>toolchain</goal>
</goals>
</execution>
</executions>
<configuration>
<toolchains>
<jdk>
<version>8</version>
</jdk>
</toolchains>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>with-doc</id>
<modules>
Expand Down
24 changes: 0 additions & 24 deletions software_development/BUILDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,27 +150,3 @@ To start the application under the root context, use:
cd web
mvn jetty:run -Dgeonetwork.webapp.contextpath=/
```


Tool chain
----------

GeoNetwork requires Java 8 at this time. If you have multiple JDK environments installed
our build can make use of an optional `~/.m2/toolchains.xml` file.

```xml
<?xml version="1.0" encoding="UTF8"?>
<toolchains>
<toolchain>
<type>jdk</type>
<provides>
<version>8</version>
</provides>
<configuration>
<jdkHome>/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home</jdkHome>
</configuration>
</toolchain>
</toolchains>
```

If the `toolchains.xml` file is available a profile will be engaged to ensure a JDK `8` is used. For more information see [guide to using toolchains](https://maven.apache.org/guides/mini/guide-using-toolchains.html).

0 comments on commit c1473f1

Please sign in to comment.