Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building branch 3.x on Windows 11 with Oracle JDK 22 failed. #467

Open
OlexYarm opened this issue Aug 3, 2024 · 1 comment
Open

Building branch 3.x on Windows 11 with Oracle JDK 22 failed. #467

OlexYarm opened this issue Aug 3, 2024 · 1 comment
Assignees

Comments

@OlexYarm
Copy link

OlexYarm commented Aug 3, 2024

Step to reproduce:

  1. Install required software (Oracle Java 22.0.1, Git 2.45.x, Git Desktop 2.50.x, Maven 3.9.x)

C:>mvn -version
Apache Maven 3.9.7 (8b094c9513efc1b9ce2d952b3b9c8eaedaf8cbf0)
Maven home: C:\Apache\apache-maven-3.9.7
Java version: 22.0.1, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-22
Default locale: en_US, platform encoding: UTF-8
OS name: "windows 11", version: "10.0", arch: "amd64", family: "windows"

C:>java -version
java version "22.0.1" 2024-04-16
Java(TM) SE Runtime Environment (build 22.0.1+8-16)
Java HotSpot(TM) 64-Bit Server VM (build 22.0.1+8-16, mixed mode, sharing)

  1. Clone 'efxclipse-rt' from GitHub (with Git or Git Desktop)

C:>gh repo clone eclipse-efx/efxclipse-rt
Cloning into 'efxclipse-rt'...
Updating files: 100% (5120/5120), done.

  1. Change directory to 'efxclipse-rt' and checkout branch 3.x

C:>cd efxclipse-rt

C:\efxclipse-rt>git checkout 3.x
Updating files: 100% (3605/3605), done.
Switched to a new branch '3.x'
branch '3.x' set up to track 'origin/3.x'.

C:\efxclipse-rt>

  1. Change directory to 'releng\org.eclipse.fx.releng'

C:\efxclipse-rt>cd releng
C:\efxclipse-rt\releng>cd org.eclipse.fx.releng

  1. Build project with Maven. The build failed with error "Unknown OSGi execution environment: 'JavaSE-22'"

C:\efxclipse-rt\releng\org.eclipse.fx.releng>mvn clean verify
[INFO] Scanning for projects...
[ERROR] Internal error: org.eclipse.tycho.core.ee.UnknownEnvironmentException: Unknown OSGi execution environment: 'JavaSE-22' -> [Help 1]
org.apache.maven.InternalErrorException: Internal error: org.eclipse.tycho.core.ee.UnknownEnvironmentException: Unknown OSGi execution environment: 'JavaSE-22'
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:109)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:904)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:281)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:204)
at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
at java.lang.reflect.Method.invoke (Method.java:580)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
Caused by: org.eclipse.tycho.core.ee.UnknownEnvironmentException: Unknown OSGi execution environment: 'JavaSE-22'
at org.eclipse.tycho.core.ee.ExecutionEnvironmentUtils.getExecutionEnvironment (ExecutionEnvironmentUtils.java:96)
at org.eclipse.tycho.core.osgitools.OsgiBundleProject.applyBestOfCurrentOrConfiguredProfile (OsgiBundleProject.java:653)
at org.eclipse.tycho.core.osgitools.OsgiBundleProject.readExecutionEnvironmentConfiguration (OsgiBundleProject.java:623)
at org.eclipse.tycho.core.resolver.DefaultTychoResolver.setupProject (DefaultTychoResolver.java:108)
at org.eclipse.tycho.core.maven.TychoMavenLifecycleParticipant.afterProjectsRead (TychoMavenLifecycleParticipant.java:111)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:223)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:904)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:281)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:204)
at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
at java.lang.reflect.Method.invoke (Method.java:580)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/InternalErrorException

C:\efxclipse-rt\releng\org.eclipse.fx.releng>

@martinbluehweis
Copy link
Member

We upgraded to java 21 in the 3.x branch (#468 ). This includes a platform update (covers also #457) and usage of a newer tycho version (which is mandatory to build with jdk 21+).

Please try again - I didn't test with jdk 22 but I don't expect any problems. Feedback is appreciated.

The nightly build doesn't contain the changes due to an infrastructure problem - we are working on that.

@martinbluehweis martinbluehweis self-assigned this Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants