Ubuntu Desktop Install and Integration with VLC

The place to discuss linux version of MakeMKV
Post Reply
MetalDave
Posts: 31
Joined: Wed May 03, 2017 10:17 pm

Ubuntu Desktop Install and Integration with VLC

Post by MetalDave »

I am running the latest Ubuntu Desktop distribution (Ubuntu 20.04.1 LTS). I have used the Snap package manager to install MakeMKV v1.15.2. All appears to work fine, but I noticed the supporting files are not being installed correctly for use with VLC and the like.

As it would appear the Integration tab only works with the Windows and Mac ports of MakeMKV (based on a thread discussing the introduction of libmmbd with MakeMKV v1.15.0), I believe manual intervention is required to achieve the same level of integration. This is no big deal as I'd been doing this prior to v1.15.0, so I'm familar with the process.

In the Direct Blu-ray playback with VLC thread, Mike provides instructions to create a symbolic link for libmmbd.so.0 in our local user library path (/usr/lib/). Assumedly, this location enables the functionality for all users on the system (rather than just installing into the ~/lib/ directory for your user only). However, I'm wondering if we're missing a couple of steps as I have VLC complaining that it cannot find libaacs for Blu-ray disc playback.

In prior versions of the application, we needed to create respective symlink aliases for libaacs or libbdplus (both pointing to libmmbd). With the introduction of the Integration tab, these symlinks were created silently in the background. For example, use of the Integration tab on macOS appears to create those aliases in the user's home folder (~/lib/) pointing back to libmmbd as follows:

Code: Select all

 ~ % ll lib
total 0
drwxr-xr-x   4 username  staff   128B Apr 29 15:45 ./
drwxr-xr-x+ 35 username  staff   1.1K Aug 11 09:41 ../
lrwxr-xr-x   1 username  staff    56B Apr 29 15:45 libaacs.dylib@ -> /Applications/MakeMKV.app/Contents/lib/libmmbd_new.dylib
lrwxr-xr-x   1 username  staff    56B Apr 29 15:45 libbdplus.dylib@ -> /Applications/MakeMKV.app/Contents/lib/libmmbd_new.dylib
 ~ % 
As shown, macOS uses the '.dylib' extension on that OS. I'm not familiar with the naming scheme on Ubuntu, but I'm guessing the extension is '.so.0' per the example in the instructions provided by Mike. If that's the case, shouldn't we also have symlinks for libaacs and libbdplus in the /usr/lib/ directory?

To be direct: is it as simple as creating a symlink called /usr/lib/libaacs.so.0 and /usr/lib/libbdplus.so.0 to libmmbd.so.0 at the MakeMKV installation location? Do we think the installation from Snap has crated some other fundamental problem? Would a complete compile do something different to fix the issue?

A little background: I am new to Ubuntu, but familiar with Linux. I'm exploring the use of Ubuntu Desktop as my OS of choice for an encoding system. This rig is, effectively, an appliance to do nothing but rip discs and encode. I'm hoping to avoid Windows altogether, and I believe the core tools I use (FFMPEG, MakeMKV, Handbrake, etc.) all offer a Linux port.
Support MakeMKV - Buy a license!
(Seriously, you use this thing enough; A lifetime license is well worth it.)

Thank you to all of my fellow supporters!
Atlas2000
Posts: 4
Joined: Tue Mar 19, 2019 2:08 pm

Re: Ubuntu Desktop Install and Integration with VLC

Post by Atlas2000 »

Hello, you can install VLC Player 3.0.1.1 in software flathub and then the extensions for Bluray java menus and encoding plugin and Makemkv plugin for VLC player. have picture attached works perfectly without copying libmbd.
Have fun everyone. mfg Atlas2000
Attachments
Bildschirmfoto von 2020-08-12 17-34-21.png
Bildschirmfoto von 2020-08-12 17-34-21.png (464.66 KiB) Viewed 18558 times
Last edited by Atlas2000 on Wed Aug 12, 2020 3:35 pm, edited 2 times in total.
MetalDave
Posts: 31
Joined: Wed May 03, 2017 10:17 pm

Re: Ubuntu Desktop Install and Integration with VLC

Post by MetalDave »

Atlas2000,

Thanks for the feedback. That's an interesting approach to address multiple areas.

First, I've heard of Flatpak as an alternative to the Ubuntu built-in Snap package manager. Similar to Snap, it doesn't look like the developers themselves are creating the distributions on Flathub in the majority of the cases. Notably, MakeMKV and VLC are community distributed. While I can find the plugins you've indicated via the GitHub repository for flathub, they don't appear to be available in the Flatpak package manager at this time. I speculate they're not maintained as the MakeMKV Plug-in for VLC hasn't been touched in 14 months (since MakeMKV v1.14.4). It looks like the same goes for the FDK-AAC Encoding (fdkaac) and Blu-ray Disc Java (bdj) plugins. That's the problem with community-driven publishing; You get the convenience, but you have no guarantee of the latest and greatest from the Developer.

Getting to the core issues, it appears the MakeMKV Plugin is, indeed, just manipulating libmmbd and creating paths to that library and makemkvcon per the code on GitHub:

Code: Select all

#!/bin/sh

export LIBAACS_PATH=/app/share/vlc/extra/makemkv/lib/libmmbd
export LIBBDPLUS_PATH=/app/share/vlc/extra/makemkv/lib/libmmbd
export MAKEMKVCON=/app/share/vlc/extra/makemkv/bin/makemkvcon
Thus, there's nothing new going on behind the curtain. Perhaps the clue given here is that we need to go into the VLC directory and create some symlinks.

I'm also learning that installing software via Snap (and I expect similar with Flatpak) does not actually unpack the content of a .snap file. This is interesting as it allows for modular software and easy updates by using a static archive. I have installed VLC using Snap, and trying to find the extra directory indicated above has been a challenge. This might lend credence to avoiding the package manager altogether as it conflicts with the instructions provided by the developer. I like the concept, so I'm going to figure out where the variable data is stored (a la plug-ins).

I'll keep investigating until I have a solid set of steps. Thanks again for the feedback; At the very least, it provided some clues.
Support MakeMKV - Buy a license!
(Seriously, you use this thing enough; A lifetime license is well worth it.)

Thank you to all of my fellow supporters!
MetalDave
Posts: 31
Joined: Wed May 03, 2017 10:17 pm

Re: Ubuntu Desktop Install and Integration with VLC

Post by MetalDave »

As I was unable to resolve the use of dynamic shared libraries with the Snap installation, I removed that application. As a next step, I installed the version from the focal repository. I used the apt package manager, but you can use the Ubuntu Software app manager to get this version via the GUI as well.

Using this method, the binary and the various packages dependencies directly into the filesystem (as you would expect). Additionally, various dynamic libraries are installed in /usr/lib/x86_64-linux-gnu/ (including older versions of libaacs and libbdplus). Installing and using additional libraries (or symlinks) in this location are easy enough and work without further intervention. I was able to get Blu-ray playback to work with libmmbd by building the symlinks for libaacs and libbdplus as follows:

Code: Select all

$ sudo rm /lib/x86_64-linux-gnu/libaacs.so.0 
$ sudo ln -s /lib/libmmbd.so.0 /lib/x86_64-linux-gnu/libaacs.so.0
$ sudo rm /lib/x86_64-linux-gnu/libbdplus.so.0 
$ sudo ln -s /lib/libmmbd.so.0 /lib/x86_64-linux-gnu/libbdplus.so.0

$ ll /lib/x86_64-linux-gnu/libbdplus.so.0 
lrwxrwxrwx 1 root root 17 Aug 26 22:36 /lib/x86_64-linux-gnu/libbdplus.so.0 -> /lib/libmmbd.so.0
$ ll /lib/x86_64-linux-gnu/libaacs.so.0
lrwxrwxrwx 1 root root 17 Aug 26 22:35 /lib/x86_64-linux-gnu/libaacs.so.0 -> /lib/libmmbd.so.0
The only drawback to the focal distribution version is that it's a revision or two behind the version distributed via Snap (v3.0.9.2-1 versus v3.0.11). Now that I have confirmed the appropriate location of the dynamic libraries with a "normal" install of VLC, I may remove and try experimenting again with the Snap. After all, VideoLAN is maintaining the Snap method directly and there are other security benefits. If the /usr/lib/x86_64-linux-gnu/ is accessible to the snap RO filesystem via some type of aliasing, I may be able to manipulate the dynamic libraries again. I'll follow up with any findings, but this will get folks running with playback in the interim.
Support MakeMKV - Buy a license!
(Seriously, you use this thing enough; A lifetime license is well worth it.)

Thank you to all of my fellow supporters!
Post Reply