negative zero

Installing VLC on Fedora

2020 March 19

[fedora] [tech] [tutorial] [vlc]


VLC media player is an excellent free software (GPLv2+) media player. Unfortunately, VLC is not included in the default Fedora dnf repositories, so we need to take some extra steps to install it.


Installing VLC

Since the Fedora Project does not include VLC in the default repos, we need to add an additional one from RPM Fusion. We will only add the free repository, so there is no need to worry about accidentally installing proprietary software.

(The VideoLAN VLC website encourages you to also enable the nonfree repo, which was the main reason I chose to write this guide rather than just link to their page.)

sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm

Now we can install VLC:

sudo dnf install vlc


Playing DVDs and Blu-ray Discs

DVDs and Blu-ray discs use DRM to prevent people from viewing them except through proprietary, restricted means. In order to watch DRM-restricted DVDs with free software, one must bypass this DRM.

The legality of this will vary by jurisdiction. See https://www.videolan.org/legal.html and your own jurisdiction's laws for more information. This information is provided here for educational purposes and should only be used where it is legal.


DVDs

If you want to watch DVDs, you will need to install libdvdcss (GPLv2). You can get it by enabling the "tainted" RPM Fusion repo. Note, this is still a repository of free software; it is so-called "tainted" because of the legal implications.

sudo dnf install rpmfusion-free-release-tainted

Now you can install libdvdcss:

sudo dnf install libdvdcss

Now you should be able to watch DVDs in VLC without issue!


Blu-ray Discs

For Blu-ray support, install libbluray (LGPLv2.1):

sudo dnf install libbluray

If you want to watch Blu-ray discs, you will also need to bypass the DRM. The library libaacs can be used for this, but it requires decryption keys which must be found elsewhere.

Assuming you have one such legally acquired key database, you can store it under the name KEYDB.cfg in the directory ~/.config/aacs/. Then just install libaacs (LGPLv2.1):

sudo dnf install libaacs

You can also install libbdplus (LGPLv2.1), which would theoretically help with discs that use BD+ in their DRM. This reportedly does not work. See the ArchWiki page on Blu-ray for more information.

sudo dnf install libbdplus

Now you should be able to watch Blu-ray discs in VLC if you have keys for them. Support for Blu-ray discs is less mature than support for DVDs, and there may be issues.