idf-eclipse-plugin: Build Failure in Eclipse 2020-09 due to Removal of Deprecated Class (IEP-242)

I just updated Eclipse to version 2020-09 and reinstalled the ESP-IDF plugin (version 1.2.2). When building a project (imported using “Import -> Existing IDF Project”), I get the following error right at the start and the build stops:

java.lang.NoClassDefFoundError: org/eclipse/cdt/utils/Platform
	at com.espressif.idf.core.build.IDFBuildConfiguration.findCommand(IDFBuildConfiguration.java:588)
	at org.eclipse.cdt.core.build.CBuildConfiguration.startBuildProcess(CBuildConfiguration.java:493)
	at com.espressif.idf.core.build.IDFBuildConfiguration.build(IDFBuildConfiguration.java:252)
	at org.eclipse.cdt.core.build.CBuilder.build(CBuilder.java:45)
	at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:832)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:220)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:263)
	at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:316)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:319)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:278)
	at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:467)
	at org.eclipse.core.internal.resources.Project$1.run(Project.java:565)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2292)
	at org.eclipse.core.internal.resources.Project.internalBuild(Project.java:603)
	at org.eclipse.core.internal.resources.Project.build(Project.java:116)
	at org.eclipse.debug.core.model.LaunchConfigurationDelegate.lambda$0(LaunchConfigurationDelegate.java:406)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2292)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2312)
	at org.eclipse.debug.core.model.LaunchConfigurationDelegate.buildProjects(LaunchConfigurationDelegate.java:412)
	at org.eclipse.debug.core.model.LaunchConfigurationDelegate.buildForLaunch(LaunchConfigurationDelegate.java:122)
	at org.eclipse.launchbar.core.target.launch.LaunchConfigurationTargetedDelegate.superBuildForLaunch(LaunchConfigurationTargetedDelegate.java:61)
	at com.espressif.idf.launch.serial.internal.SerialFlashLaunchConfigDelegate.buildForLaunch(SerialFlashLaunchConfigDelegate.java:180)
	at org.eclipse.launchbar.ui.internal.commands.BuildActiveCommandHandler$1$1.run(BuildActiveCommandHandler.java:110)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
Caused by: java.lang.ClassNotFoundException: org.eclipse.cdt.utils.Platform cannot be found by com.espressif.idf.core_1.0.0.202008190353
	at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:516)
	at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:171)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
	... 26 more

A bit of googling lead me to this page that states:

Class org.eclipse.cdt.utils.Platform has been removed. Use org.eclipse.core.runtime.Platform instead.

Seems like that was a change from 2020-06 to 2020-09, and needs to be fixed in the ESP-IDF plugin in order to support Eclipse >= 2020-09. For the time being, I’m staying with 2020-06 where everything seems to work fine.

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 9
  • Comments: 26

Most upvoted comments

@kolipakakondal Eclipse 2020-09 now works, thanks!

Thanks for verifying. I"m able to reproduce. I’ll update once the fix ready. Please continue to use Eclipse 2020-06 (4.16)

Hi All,

We will provide the fix for this soon to support the Eclipse 2020-09 version. Please continue to use Eclipse 2020-06 until then.

Hi All,

ESP-IDF Eclipse Plugin 1.2.3 is released to support Eclipse 2020-09 https://github.com/espressif/idf-eclipse-plugin/releases/tag/v1.2.3

Please update to the latest

It’s working for me, too. Thanks!

Thanks for verifying. I"m able to reproduce. I’ll update once the fix ready. Please continue to use Eclipse 2020-06 (4.16)

Hi All,

Eclipse 2020-09 support is added with this local build. This fix the issue we had with the OpenOCD Debugging launch. Could you please try and let me know how it goes. https://github.com/espressif/idf-eclipse-plugin/suites/1294855830/artifacts/20243567

To install the local build, please follow the instructions from here https://github.com/espressif/idf-eclipse-plugin#installPluginsUsingLocalFile

Hi All, Here is the local build to try out. This will fix a build failure with the Eclipse 2020-09.

com.espressif.idf.update-1.2.2-SNAPSHOT.zip

How to install this build? Check this https://github.com/espressif/idf-eclipse-plugin#installPluginsUsingLocalFile

Let me know if it helps