Page 1 of 1

Ubuntu: issues installing VLC from source code

Posted: 01 Oct 2022 00:19
by Aqualung
The SNAP-ed version doesn't do it for me, and installing using apt installs a crippled VLC version (see https://forum.videolan.org/viewtopic.php?f=13&t=160838). My only chance was to do an install from source code. For the most part that went well, except one major problem. Here's my installation process:

  • downloaded latest stable source, unzipped it into a temporary subfolder VLCTemp of my Downloads folder;
  • $ sudo apt-get build-dep vlc
  • $ cd /path/to/VLCTemp
  • $ ./configure --prefix=/usr/local/ (i.e. install VLC into "usr/local/" as recommended by the standard Linux guidelines)
  • $ sudo make install
  • deleted temporary folder VLCTemp.
So I ended up with a VLC executable file in /usr/local/bin/. Click on it, and nothing happens. Launch it form the terminal yields some error message about some library not found ... or whatever.* So I dig up the VLCTemp installation kit from the trash bin, and fire up the VLC executable in there. And whaddya know, VLC works like a charm!

Can anyone explain to me what in tarnation is going on???? VLC was explicitly (and emphatically) installed in /usr/local/, so why would I need the installation kit from the temporary folder in order to run it??

*"error while loading shared libraries: libvlc.so.5: cannot open shared object file: No such file or directory"

Re: Ubuntu: issues installing VLC from source code

Posted: 03 Oct 2022 11:26
by chubinou
maybe you have an issue with your ldconfig, see

https://stackoverflow.com/questions/474 ... -libraries

you can also try to run something like

Code: Select all

strace -e openat vlc
to see which library are used when opening your VLC installation

Re: Ubuntu: issues installing VLC from source code

Posted: 05 Oct 2022 18:01
by Aqualung
Thanks for the reply. See if you can make sense of the stuff below (I have to split it across multiple posts):

Code: Select all

dad@DadsLGGramLinux:/usr/local/bin$ strace -e openat vlc openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3 openat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v4/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v3/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v2/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/tls/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

Re: Ubuntu: issues installing VLC from source code

Posted: 05 Oct 2022 18:03
by Aqualung
Part 2:

Code: Select all

openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v4/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v3/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v2/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/tls/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v4/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v3/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v2/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/tls/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

Re: Ubuntu: issues installing VLC from source code

Posted: 05 Oct 2022 18:04
by Aqualung
Part 3:

Code: Select all

openat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v4/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v3/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v2/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/tls/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/haswell/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/haswell/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/haswell/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/haswell/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/avx512_1/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/avx512_1/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/libvlc.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) vlc: error while loading shared libraries: libvlc.so.5: cannot open shared object file: No such file or directory +++ exited with 127 +++
What am I doing wrong??

Re: Ubuntu: issues installing VLC from source code

Posted: 05 Oct 2022 18:40
by Rémi Denis-Courmont
chubinou had correctly guessed that your ldconfig is wrong, or rather it is not set up for you to install under /usr/local

Re: Ubuntu: issues installing VLC from source code

Posted: 06 Oct 2022 23:58
by Aqualung
chubinou had correctly guessed that your ldconfig is wrong, or rather it is not set up for you to install under /usr/local
Thank you! How do I fix that though? What am I doing wrong? I am following the instructions on the official Wiki page (https://wiki.videolan.org/UnixCompile/) to the letter (see above)!

Re: Ubuntu: issues installing VLC from source code

Posted: 07 Oct 2022 07:42
by Rémi Denis-Courmont
That's nothing to do with VLC compilation as such, and it works on most distribution by default, so of course it's not going to be on that page.

Re: Ubuntu: issues installing VLC from source code

Posted: 07 Oct 2022 09:59
by chubinou
> Thank you! How do I fix that though?

it's explained in the stack overflow link I put in my first post

https://stackoverflow.com/questions/474 ... -libraries

check you /etc/ld.so.conf, run ldconfig

Re: Ubuntu: issues installing VLC from source code

Posted: 07 Oct 2022 20:48
by Aqualung
Thank you! Getting closer! :)

My /etc/ld.so.conf file contains only one line, namely "include /etc/ld.so.conf.d/*.conf," so it looks like I need to add .. what? What exactly do I need to add? Here are what I see as the main choices:

1.

Code: Select all

include /usr/local
2.

Code: Select all

include /usr/local/*.conf
3.

Code: Select all

include /usr/local/lib
4.

Code: Select all

include /usr/local/lib/*.conf

So which one of these? Or is it that some of these lines should not include the "include" keyword?

Re: Ubuntu: issues installing VLC from source code

Posted: 08 Oct 2022 18:15
by Aqualung
Update: I ended up adding the following lines to /etc/ld.so.conf:

Code: Select all

/usr/local/lib /usr/local /usr

and that did it. Thanks for the help! Now, if any of these lines is not strictly required, I would appreciate your letting me know: I'd feel better knowing I have the minimal working version of /etc/ld.so.conf.

Re: Ubuntu: issues installing VLC from source code

Posted: 10 Oct 2022 09:55
by chubinou
/usr/local/lib should be enough