I am attempting to run an application based on Eclipse, and I am unable to due to errors when attempting to access libswt-pi4.so
, libswt-pi4-gtk.so
and libswt-pi4-gtk-4944r26.so
. Slight aside, I will not be going into detail regarding the application due to a NDA, but I believe it shouldn't be a problem, as the issue seems to stem from the eclipse base. I am on Linux Mint 21.2.
The error (very slightly redacted) is as follows:
!SESSION 2023-08-17 18:27:08.326 -----------------------------------------------
eclipse.buildId=unknown
java.version=11.0.15
java.vendor=Eclipse Adoptium
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Command-line arguments: -os linux -ws gtk -arch x86_64
!ENTRY org.eclipse.osgi 4 0 2023-08-17 18:27:10.417
!MESSAGE Application error
!STACK 1
java.lang.UnsatisfiedLinkError: Could not load SWT library. Reasons:
no swt-pi4-gtk-4944r26 in java.library.path: [<REDACTED>, ., /usr/java/packages/lib, /usr/lib64, /lib64, /lib, /usr/lib]
no swt-pi4-gtk in java.library.path: [<REDACTED>, ., /usr/java/packages/lib, /usr/lib64, /lib64, /lib, /usr/lib]
no swt-pi4 in java.library.path: [<REDACTED>, ., /usr/java/packages/lib, /usr/lib64, /lib64, /lib, /usr/lib]
Can't load library: /home/alexandre/.swt/lib/linux/x86_64/libswt-pi4-gtk-4944r26.so
Can't load library: /home/alexandre/.swt/lib/linux/x86_64/libswt-pi4-gtk.so
Can't load library: /home/alexandre/.swt/lib/linux/x86_64/libswt-pi4.so
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:348)
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:257)
at org.eclipse.swt.internal.gtk.OS.<clinit>(OS.java:96)
at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:209)
at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:155)
at org.eclipse.swt.widgets.Display.<clinit>(Display.java:165)
at org.eclipse.ui.internal.Workbench.createDisplay(Workbench.java:726)
at org.eclipse.ui.PlatformUI.createDisplay(PlatformUI.java:168)
at org.eclipse.ui.internal.ide.application.IDEApplication.createDisplay(IDEApplication.java:182)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:125)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:203)
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:401)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:255)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:654)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
at org.eclipse.equinox.launcher.Main.run(Main.java:1462)
at org.eclipse.equinox.launcher.Main.main(Main.java:1435)
Browsing for similar issues, I found posts suggesting I install libswt-gtk-4-java
and libswt-gtk-4-java
, which I have. This has not solved the issue. After this, another post suggested creating links from /usr/lib/jni/libswt-*
to ~/.swt/lib/linux/x86_64/
(which is indeed where the error claims the files are not), but a quick look at the original folder shows the required libraries are not there either:
alexandre:/usr/lib/jni$ l
libswt-atk-gtk-4944r26.so libswt-awt-gtk-4944r26.so libswt-gtk-4944r26.so libswt-pi3-gtk-4944r26.so
~/.swt/lib/linux/x86_64/
has a single file by default, which is libswt-pi3-gtk-4944r26.so
.
Any clue as to which packages I may be missing? Thank you for your time.