Community
Participate
Working Groups
- Launch Eclipse having Java 9 support. - Go to Run > Run Configurations... - Create a new "Eclipse Application" launch configuration. - Specify Java 9 as JRE for this launch configuration. - Apply > Run. We get this exception: !ENTRY org.eclipse.osgi 4 0 2017-09-23 00:09:11.567 !MESSAGE Application error !STACK 1 org.eclipse.e4.core.di.InjectionException: java.lang.NoClassDefFoundError: javax/annotation/PostConstruct at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:410) ... Caused by: java.lang.NoClassDefFoundError: javax/annotation/PostConstruct at org.eclipse.e4.core.internal.di.InjectorImpl.inject(InjectorImpl.java:124) at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:399) ... 23 more Caused by: java.lang.ClassNotFoundException: javax.annotation.PostConstruct cannot be found by org.eclipse.e4.core.di_1.6.100.v20170421-1418 at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:433) at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:395)
The fix is to manually add --add-modules=ALL-SYSTEM to VM arguments in Arguments tab of the launch configuration. Eclipse can add it by default when JRE 9 is being used.
Auto-update of gerrit patches on the bug is not happening. Hence Fix -> https://git.eclipse.org/r/#/c/105654/
Gerrit change https://git.eclipse.org/r/105654 was merged to [R4_7_maintenance]. Commit: http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=fecad192560bd365204946a1df5c58befd319bdc
Verified that run/debug is launching with JavaSE9 and JDK 9 in Version: Oxygen.1a (4.7.1a) Build id: M20170926-1700
New Gerrit change created: https://git.eclipse.org/r/105908
Gerrit change https://git.eclipse.org/r/105908 was merged to [master]. Commit: http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=ed6897de40cb5d8586d09dbd5336abbca529745e
Also verified on Version: Photon (4.8) Build id: I20170928-2000