Eclipse 无法在 Lubuntu 中运行?

Eclipse 无法在 Lubuntu 中运行?

我刚刚安装了 Lubuntu,但无法运行 eclipse,这是日志。Gnome 图形有问题吗?

!SESSION 2015-09-26 08:15:10.619 -----------------------------------------------
eclipse.buildId=4.5.0.I20150603-2000
java.version=1.8.0_60
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.jee.product
Command-line arguments:  -os linux -ws gtk -arch x86 -product org.eclipse.epp.package.jee.product

!ENTRY org.eclipse.osgi 4 0 2015-09-26 08:15:11.895
!MESSAGE Application error
!STACK 1
java.lang.UnsatisfiedLinkError: Could not load SWT library. Reasons: 
    /media/leader/MyData/Download/LinuxApp/eclipse/configuration/org.eclipse.osgi/744/0/.cp/libswt-pi-gtk-4527.so: libXtst.so.6: cannot open shared object file: No such file or directory
    no swt-pi-gtk in java.library.path
    /home/leader/.swt/lib/linux/x86/libswt-pi-gtk-4527.so: libXtst.so.6: cannot open shared object file: No such file or directory
    Can't load library: /home/leader/.swt/lib/linux/x86/libswt-pi-gtk.so

    at org.eclipse.swt.internal.Library.loadLibrary(Library.java:327)
    at org.eclipse.swt.internal.Library.loadLibrary(Library.java:236)
    at org.eclipse.swt.internal.gtk.OS.<clinit>(OS.java:38)
    at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:63)
    at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:54)
    at org.eclipse.swt.widgets.Display.<clinit>(Display.java:134)
    at org.eclipse.ui.internal.Workbench.createDisplay(Workbench.java:734)
    at org.eclipse.ui.PlatformUI.createDisplay(PlatformUI.java:162)
    at org.eclipse.ui.internal.ide.application.IDEApplication.createDisplay(IDEApplication.java:169)
    at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:111)
    at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
    at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
    at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:669)
    at org.eclipse.equinox.launcher.Main.basicRun(Main.java:608)
    at org.eclipse.equinox.launcher.Main.run(Main.java:1515)

答案1

您缺少 libXtst6 包内的 libXtst.so.6 文件。尝试以下操作,

sudo apt-get install libXtst6

这将使文件可用。如果这不起作用,则输出

sudo updatedb
locate libXtst.so.6

答案2

如果你安装了 Java,那么你需要从终端创建一个指向 libswt 文件的符号链接,如下所示

ln -s /usr/lib/jni/libswt-* ~/.swt/lib/linux/x86_64/

在我的 Ubuntu 12.04 32 位上。我将命令更改为:

 ln -s /usr/lib/jni/libswt-* ~/.swt/lib/linux/x86/

在 Ubuntu 12.04 64 位上你可以尝试这个:

 ln -s /usr/lib/jni/libswt-* ~/.swt/lib/linux/x86_64/

相关内容