Exhausted trying to build a command to install multimedia codecs, help needed

Hello.

So this is what i’ve come up with so far. I’m sure there are overlapping things, and others not needed, but please help me clean this up:

dnf upgrade --refresh -y && \
dnf install -y https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm && \
dnf config-manager setopt fedora-cisco-openh264.enabled=1 && \
dnf upgrade --refresh -y && \
dnf -y update @core && \
dnf swap ffmpeg-free ffmpeg --allowerasing && \
dnf -y install libavcodec-freeworld --allowerasing && \
dnf install -y rpmfusion-free-release-tainted && \
dnf install -y rpmfusion-nonfree-release-tainted && \
dnf install -y dnf-plugins-core && \
dnf install -y libdvdcss  && \
dnf group install multimedia && \
dnf group install sound-and-video && \
dnf group upgrade --with-optional Multimedia
 
dnf install -y \
gstreamer1-vaapi \
gstreamer1-plugins-base \
gstreamer1-plugins-good \
gstreamer1-plugins-good-extras \
gstreamer1-plugins-ugly-free \
gstreamer1-plugins-bad-free \
gstreamer1-libav \
gstreamer1-plugins-bad-freeworld \
gstreamer1-plugins-ugly \
gstreamer1-plugin-openh264 \
mozilla-openh264 \
pipewire-gstreamer \
svt-vp9-libs \
x265 \
x265-libs \
lame* --exclude=lame-devel

*** AMD drivers ***

dnf install -y mesa-va-drivers-freeworld mesa-vdpau-drivers-freeworld --allowerasing

*** nvidia drivers ***

dnf install -y akmod-nvidia xorg-x11-drv-nvidia-cuda xorg-x11-drv-nvidia-cuda-libs vulkan nvidia-vaapi-driver libva-nvidia-driverlibva-utils vdpauinfo nvtop && \
dnf mark user akmod-nvidia

edit: this really is way too complicated, i can’t find an official guide to install the basic things, including x.265/h.265 support which pretty much everyone needs.

Here is the official guide to install h.265 support

dnf update @multimedia --setopt="install_weak_deps=False" --exclude=PackageKit-gstreamer-plugin

That’s just a ridiculous command, who comes up with this?
Does that command exclude the gstreamer plugins?

Other guides say it’s ‘crucial’ and ‘essential’

dnf install gstreamer1-plugins-{bad-*,good-*,base} gstreamer1-plugin-openh264 gstreamer1-libav --exclude=gstreamer1-plugins-bad-free-devel

This is just so incredibly frustrating

Don’t overthink it.
If you have you needed videos running everything is good.

1 Like

I don’t understand why you need all of this. Any media I’ve run into while using Fedora 41 works with no additional software. “Out of the box”, so to say.

Years ago you may have had to go to a lot of extra effort to play some, or most, media formats, but not in 2025.

Yea, i’ll try to keep it to bare minimum… But i remember on a test system for sunshine/moonlight streaming i had to go through alot of guides to find the x265
x265-libs packages, otherwise it would not play a hevc video.

So i guess best is to do bare minimum as listed on rpmfusion pages, and then add as needed…

Wouldn’t it be nice to have a ‘dnf install non-free-codecs’ though…

based on the rpmfusion guides, this is the bare minimum:

edit1: the multimedia group seems to install most gstreamer plugins, so i added that.
edit2: (how to add strikethrough to text?) everything in multimedia group is already installed, so no need for that…
edit3: moved

dnf config-manager setopt fedora-cisco-openh264.enabled=1

to earlier, and added

dnf install -y libavcodec-freeworld

The below is my final command. I went through most commands with dnf info, and seems most things get installed this way:

dnf upgrade --refresh -y && \
dnf install -y https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm && \
dnf config-manager setopt fedora-cisco-openh264.enabled=1 && \
dnf swap ffmpeg-free ffmpeg --allowerasing && \
dnf update @multimedia --setopt="install_weak_deps=False" --exclude=PackageKit-gstreamer-plugin && \
dnf install -y rpmfusion-free-release-tainted && \
dnf install -y rpmfusion-nonfree-release-tainted && \
dnf install -y libdvdcss && \
dnf install -y libavcodec-freeworld

The rpmfusion repositories augments the multimedia group by including the freeworld packages.

1 Like

Yo, sup?

Listen, I don’t wanna be rude, but I want to tell you a little story.
In the last few days, I was struggling to install FreeBSD system and the desktop and everything about multimedia.
Want to see real pain in the ass? Try BSD too :slight_smile:
So, to be honest, I thank God that Linux (Fedora) exists and enjoy it every single day!

LOL, well yeah… The command i ended up with above seems to be about right… But it’s frustrating in the beginning when there just seems to be a bewildering amount of conflicting guides etc…

BSD on desktop… i can only imagine :grinning_face:

1 Like

right now i’m in the process of installing AMD drivers and libraries, and then verifying hw acceleration works using the guide here:

https://wiki.archlinux.org/title/Hardware_video_acceleration#AMD/ATI

So far my install command for AMD is:

dnf swap mesa-va-drivers mesa-va-drivers-freeworld -y && \
dnf swap mesa-vdpau-drivers mesa-vdpau-drivers-freeworld -y && \
dnf install -y libva-utils vdpauinfo radeontop && \
dnf install -y mpv vlc

*** confirm hw accel ***

radeontop
vainfo
vdpauinfo
vulkaninfo | grep VK_KHR_video_
mpv --hwdec=auto video_filename

Currently i’m not sure if i should have both mesa-va-drivers-freeworld and mesa-vdpau-drivers-freeworld installed at the same time, i have the notion that only vaapi is necessary if everything works…

hmm i wonder now if i should also do

dnf swap mesa-vulkan-drivers mesa-vulkan-drivers-freeworld

because running dnf install mesa-vulkan-drivers-freeworld results in:

# dnf install mesa-vulkan-drivers-freeworld
Updating and loading repositories:
Repositories loaded.
Problem: problem with installed package
  - installed package mesa-vulkan-drivers-25.0.1-2.fc41.x86_64 conflicts with mesa-vulkan-drivers(x86-64) provided by mesa-vulkan-drivers-freeworld-25.0.1-1.fc41.x86_64 from rpmfusion-free-updates
  - package mesa-vulkan-drivers-freeworld-25.0.1-1.fc41.x86_64 from rpmfusion-free-updates conflicts with mesa-vulkan-drivers(x86-64) provided by mesa-vulkan-drivers-25.0.1-2.fc41.x86_64 from updates
  - package mesa-vulkan-drivers-freeworld-25.0.1-1.fc41.x86_64 from rpmfusion-free-updates conflicts with mesa-vulkan-drivers(x86-64) provided by mesa-vulkan-drivers-24.2.4-1.fc41.x86_64 from fedora
  - cannot install the best candidate for the job

Package                                              Arch        Version                                              Repository                             Size
Installing:
 mesa-vulkan-drivers-freeworld                       i686        25.0.1-1.fc41                                        rpmfusion-free-updates            117.3 MiB
Installing dependencies:
 elfutils-libelf                                     i686        0.192-9.fc41                                         updates                             1.2 MiB
 expat                                               i686        2.7.0-1.fc41                                         updates                           299.5 KiB
 glibc                                               i686        2.40-23.fc41                                         updates                             5.5 MiB
 glibc-gconv-extra                                   i686        2.40-23.fc41                                         updates                             7.7 MiB
 libX11-xcb                                          i686        1.8.11-1.fc41                                        updates                            14.3 KiB
 libXau                                              i686        1.0.11-7.fc41                                        fedora                             62.2 KiB
 libdrm                                              i686        2.4.124-1.fc41                                       updates                           417.3 KiB
 libedit                                             i686        3.1-54.20250104cvs.fc41                              updates                           238.5 KiB
 libffi                                              i686        3.4.6-3.fc41                                         fedora                             81.5 KiB
 libgcc                                              i686        14.2.1-7.fc41                                        updates                           298.1 KiB
 libpciaccess                                        i686        0.16-13.fc41                                         fedora                             47.9 KiB
 libstdc++                                           i686        14.2.1-7.fc41                                        updates                             2.7 MiB
 libwayland-client                                   i686        1.23.0-2.fc41                                        fedora                             53.0 KiB
 libxcb                                              i686        1.17.0-3.fc41                                        fedora                              1.1 MiB
 libxml2                                             i686        2.12.10-1.fc41                                       updates                             1.8 MiB
 libxshmfence                                        i686        1.3.2-5.fc41                                         updates                            15.8 KiB
 libzstd                                             i686        1.5.7-1.fc41                                         updates                           779.7 KiB
 llvm-libs                                           i686        19.1.7-3.fc41                                        updates                           129.2 MiB
 mesa-filesystem                                     i686        25.0.1-2.fc41                                        updates                             3.6 KiB
 ncurses-libs                                        i686        6.5-2.20240629.fc41                                  fedora                            971.0 KiB
 spirv-tools-libs                                    i686        2024.4-1.fc41                                        updates                             5.8 MiB
 vulkan-loader                                       i686        1.4.304.0-1.fc41                                     updates                           562.6 KiB
 xz-libs                                             i686        1:5.6.2-2.fc41                                       fedora                            229.8 KiB
 zlib-ng-compat                                      i686        2.2.3-2.fc41                                         updates                           161.3 KiB
Skipping packages with conflicts:
 mesa-vulkan-drivers                                 x86_64      24.2.4-1.fc41                                        fedora                             98.3 MiB
 mesa-vulkan-drivers-freeworld                       x86_64      25.0.1-1.fc41                                        rpmfusion-free-updates            113.3 MiB

Transaction Summary:
 Installing:        25 packages
 Skipping:           2 packages

Total size of inbound packages is 63 MiB. Need to download 63 MiB.
After this operation, 277 MiB extra will be used (install 277 MiB, remove 0 B).
Is this ok [y/N]: n

and vulkaninfo | grep VK_KHR_video_ outputs:

# vulkaninfo | grep VK_KHR_video_
'DISPLAY' environment variable not set... skipping surface info
        VK_KHR_video_decode_av1                       : extension revision 1
        VK_KHR_video_decode_queue                     : extension revision 8
        VK_KHR_video_encode_queue                     : extension revision 12
        VK_KHR_video_maintenance1                     : extension revision 1
        VK_KHR_video_queue

suggesting that h264 and h265 support is missing as documented in the arch documentation. Anyone know?

edit1:

yes, dnf swap mesa-vulkan-drivers mesa-vulkan-drivers-freeworld went error free, and after that the vulkan output is

VK_KHR_video_decode_av1                       : extension revision 1
        VK_KHR_video_decode_h264                      : extension revision 9
        VK_KHR_video_decode_h265                      : extension revision 8
        VK_KHR_video_decode_queue                     : extension revision 8
        VK_KHR_video_encode_h264                      : extension revision 14
        VK_KHR_video_encode_h265                      : extension revision 14
        VK_KHR_video_encode_queue                     : extension revision 12
        VK_KHR_video_maintenance1                     : extension revision 1
        VK_KHR_video_queue                            : extension revision 8

progress!