Quelea icon indicating copy to clipboard operation
Quelea copied to clipboard

VLC Not Detected

Open HeyITGuyFixIt opened this issue 2 years ago • 30 comments

I load Quelea 2022.0 (installed from snap on Linux Mint 20 Ulyana, based on Ubuntu 20.04 focal), and I get a message saying to install VLC. It has been installed, so I'm not sure what's wrong. The error log has this:

May 07, 2022 5:52:21 PM org.quelea.windows.multimedia.VLCWindowEmbed lambda$new$2
INFO: Couldn't initialise video, almost definitely because VLC (or correct version of VLC) was not found.
java.lang.RuntimeException: Failed to load the native library.

The error was "Unable to load library 'vlc':
libvlc.so: cannot open shared object file: No such file or directory
libvlc.so: cannot open shared object file: No such file or directory
Native library (linux-x86-64/libvlc.so) not found in resource path (/snap/quelea/950/jar/Quelea.jar)".

The required native libraries are named "libvlc.so" and "libvlccore.so".

In the text below <libvlc-path> represents the name of the directory containing "libvlc.so" and "libvlccore.so"...

There are a number of different ways to specify where to find the native libraries:
 1. Include NativeLibrary.addSearchPath("vlc", "<libvlc-path>"); at the start of your application code.
 2. Include System.setProperty("jna.library.path", "<libvlc-path>"); at the start of your application code.
 3. Specify -Djna.library.path=<libvlc-path> on the command-line when starting your application.
 4. Add <libvlc-path> to the system search path (and reboot).

If this still does not work, then it may be necessary to explicitly add the native library directory to the operating
system configuration - e.g. on Linux this might mean setting the LD_LIBRARY_PATH environment variable, or adding
configuration to the "/etc/ld.so.conf" file or the "/etc/ld.so.conf.d" directory. Of these options, setting
LD_LIBRARY_PATH is the only one that would not require root privileges.

Finally, it is not possible to mix CPU architectures - it is not possible for a 64-bit Java Virtual Machine to load
32-bit native libraries.

More information may be available in the log.

	at uk.co.caprica.vlcj.binding.LibVlcFactory.create(LibVlcFactory.java:198)
	at uk.co.caprica.vlcj.player.MediaPlayerFactory.<init>(MediaPlayerFactory.java:285)
	at org.quelea.windows.multimedia.VLCWindowEmbed.lambda$new$2(VLCWindowEmbed.java:173)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)

libvlc.so is at /usr/lib/x86_64-linux-gnu/libvlc.so and $PATH is set to:

/usr/lib/x86_64-linux-gnu/:/home/tgocala/.nvm/versions/node/v14.18.0/bin:/usr/lib/x86_64-linux-gnu/:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/opt/gfie-3.6:/opt/gfie-3.6

The folder libvlc.so is found in is listed in /etc/ld.so.conf.d/x86_64-linux-gnu.conf. Not sure what else to do to fix this.

HeyITGuyFixIt avatar May 07 '22 22:05 HeyITGuyFixIt

VLC version:

VLC media player 3.0.9.2 Vetinari (revision 3.0.9.2-0-gd4c1aefe4d)

HeyITGuyFixIt avatar May 07 '22 23:05 HeyITGuyFixIt

Have you definitely installed the 64 bit version of VLC? The path (x86_64) suggests that might be the 32 bit library.

berry120 avatar May 08 '22 14:05 berry120

It is the same problem here.

/usr/lib/libvlccore.so: symbolic link to libvlccore.so.9.0.0 /usr/lib/libvlccore.so.9: symbolic link to libvlccore.so.9.0.0 /usr/lib/libvlccore.so.9.0.0: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=34cf0e37ea426bc7046fd3f7b95f7f70e8a119d6, stripped /usr/lib/libvlc.so: symbolic link to libvlc.so.5.6.0 /usr/lib/libvlc.so.5: symbolic link to libvlc.so.5.6.0 /usr/lib/libvlc.so.5.6.0: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=fd3c6ac9f38876ce260950fee12df83d8b3177a2, stripped

frebergguru avatar May 10 '22 12:05 frebergguru

I am running quelea under linux Manjaro Kde. I have the same problem, quelea2022 don't see VLC, I have been VLC user for many years. Is it possible to install quelea2021 via snap, while I am waiting for a solution of the problem with vlc with quelea2022. I need to run videos in quelea.

helgeheo avatar May 10 '22 14:05 helgeheo

Is this a regression in 2022 (did it work ok in 2021?)

berry120 avatar May 11 '22 10:05 berry120

(Sorry, fat-fingered the button, didn't mean to close)

berry120 avatar May 11 '22 10:05 berry120

In 2021 there is no question of vlc, and it was possible to run videos. In 2022, I am not able to run videos as long as quelea don't see vlc.

helgeheo avatar May 11 '22 10:05 helgeheo

@berry120 I purged vlc and all packages with vlc in their names, and reinstalled them explicitly specifying to install the amd64 versions. And it still doesn't detect vlc.

HeyITGuyFixIt avatar May 14 '22 22:05 HeyITGuyFixIt

Just a quick note to say I can reproduce this, am working on a fix, but unfortunately haven't managed to narrow down exactly what's going on yet. Only seems to happen with the snap version which makes debugging & releasing a pain. I am actively looking at it whenever I can though.

berry120 avatar May 14 '22 22:05 berry120

This issue has been mentioned on Quelea community. There might be relevant details there:

https://quelea.discourse.group/t/quelea-2022/841/13

quelea-bot avatar May 21 '22 00:05 quelea-bot

This issue has been mentioned on Quelea community. There might be relevant details there:

https://quelea.discourse.group/t/vlc-issues/854/6

quelea-bot avatar May 21 '22 00:05 quelea-bot

Update on this one - unfortunately it doesn't seem to be as simple as widening the path, as (at least on my test VM) the VLC library loads ok but causes a hard crash after playing a video for the first time.

For anyone who wants to test to see / confirm if the same behaviour happens to them, that'd be much appreciated just to check it's not something odd with my setup. (You can do so by temporarily installing the "edge" release of the snap - snap install quelea --edge - but it's definitely not stable at the moment so please make sure you don't do that on a system where you rely on Quelea to work!)

berry120 avatar May 21 '22 00:05 berry120

@berry120 not sure what error you get, but when I try it I get an error from vlc saying:

vdpau_avcodec generic error: Xlib is required for VDPAU

That results in a fatal JRE error from ld-linux-x86-64.so.2+0xcc78.

It happens when a video stops playing. Whether as a song background or just a video on loop or not. As a song background or as a video on loop, it crashes right as it is about to loop.

Now my setup is kinda weird. It's my laptop running Ubuntu Server (focal), and I've manually added the needed display software for x11. I'm not sure if I'm missing something that causes this or if this is the same error you get.

HeyITGuyFixIt avatar May 21 '22 18:05 HeyITGuyFixIt

The error I get is also in ld-linux-x86-64.so.2+0xcc78 - I don't get the Xlib warning though so not sure if that's related, or a red herring. Regardless, thanks very much for the confirmation and I'll keep digging.

On Sat, 21 May 2022 at 19:11, Christian Sirolli @.***> wrote:

@berry120 https://github.com/berry120 not sure what error you get, but when I try it I get an error from vlc saying:

vdpau_avcodec generic error: Xlib is required for VDPAU

That results in a fatal JRE error from ld-linux-x86-64.so.2+0xcc78.

It happens when a video stops playing. Whether as a song background or just a video on loop or not. As a song background or as a video on loop, it crashes right as it is about to loop.

Now my setup is kinda weird. It's my laptop running Ubuntu Server (focal), and I've manually added the needed display software for x11. I'm not sure if I'm missing something that causes this or if this is the same error you get.

— Reply to this email directly, view it on GitHub https://github.com/quelea-projection/Quelea/issues/547#issuecomment-1133745600, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQBHVHQAMVC634Q3YB3ZYPTVLERLPANCNFSM5VK7T3OA . You are receiving this because you commented.Message ID: @.***>

-- Thanks,

Michael

quelea-bot avatar May 21 '22 18:05 quelea-bot

That could be specific to my setup.

HeyITGuyFixIt avatar May 21 '22 18:05 HeyITGuyFixIt

@berry120 any updates on this?

HeyITGuyFixIt avatar Jun 06 '22 10:06 HeyITGuyFixIt

Afraid not (at least not yet.) Tried a few things that made no difference, I need to put aside a solid block of time to take a look and unfortunately things are very busy here at the moment. Feel free to keep hassling me on it though :-)

On Mon, 6 Jun 2022 at 11:24, Christian Sirolli @.***> wrote:

@berry120 https://github.com/berry120 any updates on this?

— Reply to this email directly, view it on GitHub https://github.com/quelea-projection/Quelea/issues/547#issuecomment-1147296064, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQBHVHR456IMUJEKQRWJJPLVNXGWXANCNFSM5VK7T3OA . You are receiving this because you commented.Message ID: @.***>

-- Thanks,

Michael

quelea-bot avatar Jun 08 '22 06:06 quelea-bot

Same issue.

LAfricain avatar Jun 23 '22 09:06 LAfricain

@berry120 hassling you again, any updates?

HeyITGuyFixIt avatar Jul 09 '22 21:07 HeyITGuyFixIt

I also have this problem on Ubuntu 20.04 has anybody tested it on Ubuntu 22.04?

Waterkloof avatar Jul 28 '22 05:07 Waterkloof

I think this is a common problem for all linux distros

helgeheo avatar Jul 28 '22 08:07 helgeheo

@berry120 bugging you again. Can I help with anything?

HeyITGuyFixIt avatar Aug 01 '22 10:08 HeyITGuyFixIt

Hey, sorry for the silence on this one - things at the "real job" have been rather busy as of late!

Current status is that I'm seeing if I can just bundle a pre-packaged release of VLC into Quelea rather than relying on a snap dependency, therefore sidestepping the issue that JNA seem to have when loading the universal binaries (I'm still not sure why this is the case.) That's proving annoyingly time consuming however. I'll post back when I have a more concrete update.

On Mon, 1 Aug 2022 at 11:30, Christian Sirolli @.***> wrote:

@berry120 https://github.com/berry120 bugging you again. Can I help with anything?

— Reply to this email directly, view it on GitHub https://github.com/quelea-projection/Quelea/issues/547#issuecomment-1201017558, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ6JDIBTQCZZG4UNA5Q4BLVW6RLNANCNFSM5VK7T3OA . You are receiving this because you were mentioned.Message ID: @.***>

-- Thanks,

Michael

berry120 avatar Aug 01 '22 10:08 berry120

On Ubuntu 22.04.1 LTS with the latest quelea edge snap:

  • VLC plays a schedule video (added to the schedule using Add Multimedia)
  • But when the video ends Quelea aborts and has to be restarted.
  • Also, when during the video display a next schedule song item is selected and Go Live is pushed: Quelea aborts and has to be restarted.

S1

DeeTigIT avatar Aug 18 '22 18:08 DeeTigIT

This issue has been mentioned on Quelea community. There might be relevant details there:

https://quelea.discourse.group/t/unable-to-run-vlc-background-videos-on-latest-version-2022-quelea/890/2

quelea-bot avatar Aug 27 '22 08:08 quelea-bot

I just wanted to check to see if there had been any progress for this. I am hoping to include the Quelea Snap package in the UbuntuCE Software Center. I totally understand how it goes with balancing the "real job" and the passion projects. Believe me! :) Thanks for the hard work Quelea.

jeremehancock avatar Aug 31 '22 12:08 jeremehancock

@jeremehancock No solid progress yet I'm afraid, I need to find another solid block of time to look at it, and time is proving hard to find at the moment!

berry120 avatar Sep 07 '22 15:09 berry120

@jeremehancock No solid progress yet I'm afraid, I need to find another solid block of time to look at it, and time is proving hard to find at the moment!

Thank you for the update. I completely understand!

jeremehancock avatar Sep 08 '22 12:09 jeremehancock

Taking another look at things I think we'll maybe need to look at bundling a version of VLC in the snap itself, so that's the approach I'll look at next. Have just wound back a bunch of experimental changes that I'd made in the hope that we could avoid this (in order to get a smaller & more efficient snap), but alas it wasn't to be.

berry120 avatar Oct 01 '22 00:10 berry120

Fingers crossed. I appreciate the update. I really appreciate it.

jeremehancock avatar Oct 01 '22 01:10 jeremehancock