使用 synaptics 在 Ubuntu 18.04 中安装 eclipse 后,应用程序无法启动,显示错误

使用 synaptics 在 Ubuntu 18.04 中安装 eclipse 后,应用程序无法启动,显示错误

我正在使用 Ubuntu 18.04。我使用 synaptics 安装 eclipse。在那里,我选择了默认的 eclipse 和 synaptics 标记的默认依赖项,应用它们,然后关闭 synaptics。

现在,当我按下键盘上的窗口键并在搜索栏中输入 eclipse 时,会出现 eclipse 图标。单击图标时,eclipse 应用程序无法启动。相反,我得到一个弹出菜单,显示

发生错误。查看日志文件 /home/username/.eclipse/org.eclipse.platform_3.8_155965261/configuration/1528986311505.log

另外,如果我尝试从终端打开 eclipse,也会发生同样的事情

命令

java -version

给出结果

openjdk version "10.0.1" 2018-04-17
OpenJDK Runtime Environment (build 10.0.1+10-Ubuntu-3ubuntu1)
OpenJDK 64-Bit Server VM (build 10.0.1+10-Ubuntu-3ubuntu1, mixed mode)

日志文件的内容为:

!SESSION Thu Jun 14 19:55:11 IST 2018
------------------------------------------ !ENTRY org.eclipse.equinox.launcher 4 0 2018-06-14 19:55:11.579 !MESSAGE Exception launching the Eclipse Platform: !STACK java.lang.ClassNotFoundException: org.eclipse.core.runtime.adaptor.EclipseStarter
        at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:466)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:566)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:499)
        at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:626)
        at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
        at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
        at org.eclipse.equinox.launcher.Main.main(Main.java:1414)

~

那么如何解决这个问题?

答案1

Ubuntu 18.04(和 18.04.1)中的 eclipse 版本已损坏。

几乎没有人使用 ubuntu 提供的 eclipse 版本。您应该按照以下过程操作https://doc.ubuntu-fr.org/eclipse#installation_par_le_nouvel_outil_eclipse_installer并安装较新的版本。

相关内容