Gradle comply about unsupported Java Version [message #1868163] |
Sat, 13 July 2024 02:57  |
Eclipse User |
|
|
|
I created a simple Java Application in Eclipse to test building and deployment. I set the project target Java Version to 17. The application runs fine within the IDE by selecting "run as java application".
Now I want to build a runnable .jar package.
Therefore I created a "run configuration" in "gradle task". Is this the correct way?
If I run this gradle task I get:
The supplied phased action failed with an exception.
Could not open cp_init generic class cache for initialization script 'C:\Users\***\eclipse-workspace\.metadata\.plugins\org.eclipse.buildship.core\init.d\eclipsePlugin.gradle' (C:\Users\***\.gradle\caches\8.1.1\scripts\2to4is5l87jn9v7vrcgka57e).
BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 66
This message makes no sense since I have no JRE 22 (Version 66) installed.
The one and only listed and to eclipse known JRE in the "window - preferences - Java - Installed Java JREs" table is my installed JRE 17.
In all the bunch of settings tables and files in eclipse I cannot find a setting which tells gradle "use JRE 22".
How do I have to configure gradle to build a runnable .jar package?
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.08106 seconds