Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libffi.so.7 missing from linux libs #219

Open
mgunyho opened this issue Aug 20, 2023 · 0 comments
Open

libffi.so.7 missing from linux libs #219

mgunyho opened this issue Aug 20, 2023 · 0 comments

Comments

@mgunyho
Copy link

mgunyho commented Aug 20, 2023

Hi, I was trying to play a video file with Processing on openSUSE Tumbleweed. I first ran into #214, but after fixing the symlinks, if I try to run any of the examples I get the error

can't load library gobject-2.0 (gobject-2.0|libgobject-2.0|libgobject-2.0-0) with -Djna.library.path=~/sketchbook/libraries/video/library/linux-amd64. Last error:java.lang.UnsatisfiedLinkError: Unable to load library 'gobject-2.0':
libffi.so.7: cannot open shared object file: No such file or directory
libffi.so.7: cannot open shared object file: No such file or directory
/usr/lib64/libgobject-2.0.so.0.7600.4: undefined symbol: g_bookmark_file_copy
Native library (linux-x86-64/libgobject-2.0.so) not found in resource path (/tmp/processing/Loop17380185095420067892temp:~/Apps/processing/processing-4.3/core/library/jogl-all.jar:~/Apps/processing/processing-4.3/core/library/gluegen-rt.jar:~/Apps/processing/processing-4.3/core/library/core.jar:~/sketchbook/libraries/video/library/gst1-java-core-1.4.0.jar:~/sketchbook/libraries/video/library/video.jar:~/sketchbook/libraries/video/library/jna.jar)
/lib64/libgobject-2.0.so.0: undefined symbol: g_bookmark_file_copy
/lib64/libgobject-2.0.so.0: undefined symbol: g_bookmark_file_copy
/lib64/libgobject-2.0.so.0: undefined symbol: g_bookmark_file_copy
Native library (linux-x86-64/libgio-2.0.so) not found in resource path

... and a bunch of other errors, many (all?) of the .so libraries fail to load.

This seems to be because my distro doesn't ship libffi.so.7, but .so.8, which is backwards incompatible (the ABI was changed in libffi 3.4.0 released in 2021). So I think either the libraries should be updated to later versions which presumably use libffi.so.8, or libffi7 should be bundled along with the other libs. I see that libffi-7 is bundled in the mingw version here, but it's not in the list of linux libs.

workaround

I was able to work around this by manually downloading libffi.so.7 from an RPM distribution site, placing it next to the other libs, and then running sketches from the terminal with LD_LIBRARY_PATH set:

$ export LD_LIBRARY_PATH=~/sketchbook/libraries/video/library/linux-amd64/ 
$ processing-java --sketch=path_to_sketch --run

This gets rid of all the .so errors. I wasn't able to set the LD_LIBRARY_PATH for the processing IDE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant