java.lang.UnsatisfiedLinkError: no swt-gtk-3557 or swt-gtk in swt.library.path, java.library.path or the jar file

Bug #620516 reported by Andreas Schildbach
60
This bug affects 12 people
Affects Status Importance Assigned to Milestone
eclipse (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: eclipse

The just released eclipse package for Maverick that comes with JDT (hooray!) crashes on start. See attached .log

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: eclipse (not installed)
ProcVersionSignature: Ubuntu 2.6.35-15.21-generic 2.6.35.1
Uname: Linux 2.6.35-15-generic x86_64
Architecture: amd64
Date: Thu Aug 19 18:04:10 2010
InstallationMedia: Ubuntu 10.10 "Maverick Meerkat" - Alpha amd64 (20100630.2)
ProcEnviron:
 LANG=en_US.utf8
 SHELL=/bin/bash
SourcePackage: eclipse
xulrunner-versions:
 /usr/lib/xulrunner-1.9.2.7
 /usr/lib/xulrunner-1.9.2.9pre

Revision history for this message
Andreas Schildbach (schildbach) wrote :
Revision history for this message
Niels Thykier (niels-thykier) wrote :

Hi,

Exactly which eclipse packages do you have installed? The output of:
  dpkg -l | grep eclipse
should do just fine.

What is the output of:
  find ~/.eclipse /usr/lib/jni/ -name '*swt*'
  find /usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/ -name '*swt*'

Also you appear to have two versions of xulrunner installed; eclipse has been known to handle this very poorly. I doubt this is your current problem, but you could very well run into problems with that if this problem is solved.

Thank you in advance,
~Niels

Changed in eclipse (Ubuntu):
status: New → Incomplete
Revision history for this message
Mingming Ren (portis25) wrote :

Hello,
I have the same problem. Here's some information.

$ dpkg -l | grep eclipse
ii eclipse 3.5.2-5 Extensible Tool Platform and Java IDE
ii eclipse-jdt 3.5.2-5 Eclipse Java Development Tools (JDT)
ii eclipse-pde 3.5.2-5 Eclipse Plug-in Development Environment (PDE)
ii eclipse-platform 3.5.2-5 Eclipse platform without plug-ins to develop any language
ii eclipse-platform-data 3.5.2-5 Eclipse platform without plug-ins to develop any language (data)
ii eclipse-plugin-cvs 3.5.2-5 Eclipse Team Integration (CVS support)
ii eclipse-rcp 3.5.2-5 Eclipse Rich Client Platform (RCP)

$ find ~/.eclipse /usr/lib/jni/ -name '*swt*'
/usr/lib/jni/libswt-mozilla-gtk-3555.so
/usr/lib/jni/libswt-atk-gtk-3555.so
/usr/lib/jni/libswt-cairo-gtk-3555.so
/usr/lib/jni/libswt-xpcominit-gtk-3555.so
/usr/lib/jni/libswt-xulrunner-gtk-3555.so
/usr/lib/jni/libswt-gtk-3555.so
/usr/lib/jni/libswt-glx-gtk-3555.so
/usr/lib/jni/libswt-gnome-gtk-3555.so
/usr/lib/jni/libswt-pi-gtk-3555.so
/usr/lib/jni/libswt-awt-gtk-3555.so

$ find /usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/ -name '*swt*'
it finds nothing.

It seems that eclipse is trying to load swt 3557, but only 3555 is present. I tried to make soft link but still failed.
By the way, I have only one version of xulrunner.

$ dpkg -l | grep xulrunner
ii xulrunner-1.9.2 1.9.2.8+build1+nobinonly-0ubuntu1 XUL + XPCOM application runner

Thanks

Revision history for this message
Mingming Ren (portis25) wrote :

Ok, I just upgrade eclipse to 3.5.2-6, and this problem seems fixed.

Now I got
$ find /usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/ -name '*swt*'
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-pi-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-atk-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-awt-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-xulrunner-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-glx-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-gnome-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-cairo-gtk-3557.so
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-xpcominit-gtk-3557.so

Changed in eclipse (Ubuntu):
status: Incomplete → Fix Released
Revision history for this message
Andreas Schildbach (schildbach) wrote :

I can confirm that this has been fixed with 3.5.2-6. Thanks!

Revision history for this message
Jan Tymiński (tymikk) wrote :

It happens to me since last eclipse update (yesterday or the day before yesterday). Currently I have version: 3.5.2-8ubuntu2.
I'm working on 11.04 (natty).
Problem is exactly as above, eclipse wantsswt-gtk-3557, but only -3555 present. As solution in here is upgrading eclipse - won't work for me now, as it's up to date.

When I want to start eclipse, it fails and generates it:

!ENTRY org.eclipse.osgi 4 0 2011-03-03 20:32:25.056
!MESSAGE Application error
!STACK 1
java.lang.UnsatisfiedLinkError: no swt-gtk-3557 or swt-gtk in swt.library.path, java.library.path or the jar file
 at org.eclipse.swt.internal.Library.loadLibrary(Library.java:254)
 at org.eclipse.swt.internal.Library.loadLibrary(Library.java:159)
 at org.eclipse.swt.internal.C.<clinit>(C.java:21)
 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:131)
 at org.eclipse.ui.internal.Workbench.createDisplay(Workbench.java:516)
 at org.eclipse.ui.PlatformUI.createDisplay(PlatformUI.java:161)
 at org.eclipse.ui.internal.ide.application.IDEApplication.createDisplay(IDEApplication.java:143)
 at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:88)
 at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.lang.reflect.Method.invoke(Method.java:616)
 at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:559)
 at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
 at org.eclipse.equinox.launcher.Main.run(Main.java:1311)

Revision history for this message
Simon Charette (charettes) wrote :

I'm having the same issue as Jan with fresh natty alpha 3 64 bit open jdk.

Revision history for this message
Octavian Damiean (mainerror) wrote :

I can confirm this also on Natty Alpha 3 64bit.

Revision history for this message
Wouter Deconinck (wdconinc) wrote :

I can confirm this problem as well. Attached are some diagnostics (as requested earlier).

Revision history for this message
Wouter Deconinck (wdconinc) wrote :
Revision history for this message
Wouter Deconinck (wdconinc) wrote :
Revision history for this message
cedric (cedric) wrote :

This also affects me on alpha3 32bits.

Revision history for this message
Wouter Deconinck (wdconinc) wrote :

See also bug 728825... which is confirmed and critical. New info is probably better added there.

Revision history for this message
johnj (johnleejacobs) wrote :

This is also affecting me on Natty Alpha 3, x86_64

Revision history for this message
Krish (mail-me-in) wrote :

Same here on Natty alpha 3.

Revision history for this message
Henrique Rocha (hmrocha-fc) wrote :

Also happens to me.
I've just installed Eclipse using apt-get install eclipse-jdt because I want to start looking into Android development.

Revision history for this message
Henrique Rocha (hmrocha-fc) wrote :

I forgot to add that I'm using a freshly updated natty alpha 3.

Revision history for this message
Alejandro Piñeiro (apinheiro) wrote :

I also had this problem using Ubuntu oneiric. I have this eclipse packages installed:

ii eclipse 3.5.2-11ubuntu1 Extensible Tool Platform and Java IDE
ii eclipse-jdt 3.5.2-11ubuntu1 Eclipse Java Development Tools (JDT)
ii eclipse-pde 3.5.2-11ubuntu1 Eclipse Plug-in Development Environment (PDE)
ii eclipse-platform 3.5.2-11ubuntu1 Eclipse platform without plug-ins to develop any language
ii eclipse-platform-data 3.5.2-11ubuntu1 Eclipse platform without plug-ins to develop any language (data)
ii eclipse-plugin-cvs 3.5.2-11ubuntu1 Eclipse Team Integration (CVS support)
ii eclipse-rcp 3.5.2-11ubuntu1 Eclipse Rich Client Platform (RCP)

And this java ones:

ii sun-java6-bin 6.26-1natty1 Sun Java(TM) Runtime Environment (JRE) 6 (architecture dependent files)
ii sun-java6-demo 6.26-1natty1 Sun Java(TM) Development Kit (JDK) 6 demos and examples
ii sun-java6-jdk 6.26-1natty1 Sun Java(TM) Development Kit (JDK) 6
ii sun-java6-jre 6.26-1natty1 Sun Java(TM) Runtime Environment (JRE) 6 (architecture independent files)

On the .log I found this error message:
java.lang.UnsatisfiedLinkError: no swt-pi-gtk-3557 or swt-pi-gtk in swt.library.path, java.library.path or the jar file

Doing a dpkg -S:
dpkg -S swt-pi-gtk*
eclipse-rcp: /usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/145/1/.cp/libswt-pi-gtk-3557.so

*But*, if I do a find on /usr/lib:
find "/usr/lib" -name "libswt-pi-gtk*"
/usr/lib/eclipse/configuration/org.eclipse.osgi/bundles/146/1/.cp/libswt-pi-gtk-3557.so

Notice that one says 145 and the other 146.

Should I re-open this bug or create a new one for Oneiric?

Revision history for this message
Alejandro Piñeiro (apinheiro) wrote :

Well, I can't re-open this bug, but just to comment that using eclipse directly from the official webpage is working properly

Revision history for this message
John Hoebing (jlhsage) wrote :

Same problem here on Oneiric alpha2 x86_64 updated as of today. I'm going
to remove all my eclipse selections in synaptic and try the official eclipse
webpage download. I think there should be an open bug on this issue.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.