forked from eclipse-xtext/xtext
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Build with Tycho 3.0.4 and set up Maven toolchains
General guide for Maven toolchains: https://maven.apache.org/guides/mini/guide-using-toolchains.html Using the Maven-Toolchain-Plugin and its 'toolchain' goal the maven-compiler-plugin is configured to use a JDK from the toolchain that matches the specified release version. Configure the Tycho-Compiler-Plugin to use the JDK in the toolchain that matches the Bundle-RequiredExecutionEnvironment: https://tycho.eclipseprojects.io/doc/3.0.4/tycho-compiler-plugin/compile-mojo.html#useJDK Configure the Maven-Surefire-Plugin to use a specific JDK version from the toolchain to launch a test runtime: https://maven.apache.org/surefire/maven-surefire-plugin/test-mojo.html#jdkToolchain Configure the Tycho-Surefire-Plugin to use a specific JDK version from the toolchain to launch a test runtime: https://tycho.eclipseprojects.io/doc/3.0.4/tycho-surefire-plugin/test-mojo.html#useJDK About the toolchains.xml generated by the setup-java Github action and the exported JAVA_HOME_ environment variables: - https://github.com/actions/setup-java/#install-multiple-jdks - https://github.com/actions/setup-java/blob/main/docs/advanced-usage.md#Modifying-Maven-Toolchains Fixes eclipse-xtext#2216 Co-authored-by: Lorenzo Bettini <[email protected]>
- Loading branch information
1 parent
579935e
commit 6381d98
Showing
3 changed files
with
59 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?xml version="1.0" encoding="UTF8"?> | ||
<toolchains xmlns="https://maven.apache.org/TOOLCHAINS/1.1.0" | ||
xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="https://maven.apache.org/TOOLCHAINS/1.1.0 https://maven.apache.org/xsd/toolchains-1.1.0.xsd"> | ||
<toolchain> | ||
<type>jdk</type> | ||
<provides> | ||
<id>JavaSE-11</id> | ||
<version>11</version> | ||
</provides> | ||
<configuration> | ||
<jdkHome>${env.JAVA_HOME_11_X64}</jdkHome> | ||
</configuration> | ||
</toolchain> | ||
<toolchain> | ||
<type>jdk</type> | ||
<provides> | ||
<id>JavaSE-17</id> | ||
<version>17</version> | ||
</provides> | ||
<configuration> | ||
<jdkHome>${env.JAVA_HOME_17_X64}</jdkHome> | ||
</configuration> | ||
</toolchain> | ||
</toolchains> |