This is a step by step guide shows how to install the popular HandBrake video transcoder in Debian 12 Bookworm.
HandBrake is a free and open-source app to convert your videos to make them work on mobile phone, tablet, TV media player, game console, or web browser.
HandBrake is available in Debian repository, but old! For the most recent version (1.9.0 so far), you may install it with either way below:
- official Flatpak package, runs in sandbox.
- native .deb package, maintained by deb-multimedia repository.
Option 1: Install HandBrake via Flatpak package
HandBrake website now provides official Linux package through Flatpak package. It works in most Linux and even Chrome OS, however runs in sandbox environment.
First, press Ctrl+Alt+T
to open up a terminal window. Then run command to install the Flatpak daemon:
sudo apt install flatpak
Other Linux can follow this setup guide to enable Flatpak support.
Next, run command to install the app as Flatpak package:
flatpak install https://dl.flathub.org/repo/appstream/fr.handbrake.ghb.flatpakref
The app needs a separated GNOME and freedesktop platforms (also installed in sandbox), so there will be lots of download as the screenshot below shows you.
After installed the package, just search for and launch it from start menu. If app icon is not visible, either log out and back in, or run the command below to start from terminal:
flatpak run fr.handbrake.ghb
And, to check updates for the HandBrake Flatpak package, use command:
flatpak update fr.handbrake.ghb
Option 2: Install HandBrake native .deb package
Deb Multimedia is a very popular Debian repository that hosts tons of .deb
packages for multimedia applications and libraries, including HandBrake.
1. Add Deb Multimedia repository
First, open up a terminal window either from start menu or by pressing Ctrl+Alt+T
on keyboard.
When it opens, run command to create a source file with nano
command line text editor:
sudo nano /etc/apt/sources.list.d/deb-multimedia.sources
There copy and paste the following lines into the file:
Types: deb
URIs: https://www.deb-multimedia.org
Suites: bookworm bookworm-backports
Components: main
Signed-By: /etc/apt/keyrings/deb-multimedia-keyring.gpg
Finally, press Ctrl+S to save and Ctrl+X to eixt.
2. Download & install the key
To make your system trust the package from that repository, you also need to download & install the GPG key.
First, click the button below to go to the web page, and click download the most recent .deb
package:
Then, run command in terminal to install it:
sudo apt install ~/Downloads/deb-multimedia-keyring*.deb
It will automatically install the key file to /etc/apt/keyrings
directory mentioned in the last step.
3. Set Priority (Optional)
The Deb Multimedia repository includes tons of other apps and libraries. You may set a lower priority for that repository, so it won’t install updates from it unless you intent to.
First, run command to create a config file for apt
package manager:
sudo nano /etc/apt/preferences.d/99deb-multimedia
Then, add the lines below:
Package: *
Pin: origin www.deb-multimedia.org
Pin-Priority: 1
Finally, press Ctrl+X, type y and hit Enter to save file.
4. Refresh cache & install HandBrake
Finally, run command to refresh system package cache:
sudo apt update
And, install HandBrake from deb multimedia repository:
sudo apt install handbrake-gtk -t "o=Unofficial Multimedia Packages"
Here -t
flag plus the keyword under double quotation marks tells where to install the package from. For choice, you may replace handbrake-gtk
in command with handbrake-cli
to install the command line tool.
Uninstall HandBrake in Debian
To uninstall the Flatpak package, use command:
flatpak uninstall --delete-data fr.handbrake.ghb
Also run flatpak uninstall --unused
to remove useless run-times.
To uninstall the .deb packge, run command:
sudo apt remove --autoremove handbrake-cli handbrake-gtk
Also, remove the deb-multimedia repository by removing the source and key files:
- To remove the source file, run command:sudo rm /etc/apt/sources.list.d/deb-multimedia.sources
- To remove the GPG key:sudo rm /etc/apt/keyrings/deb-multimedia-keyring.gpg
- You may also remove the config file for the package priority:
sudo rm /etc/apt/preferences.d/99deb-multimedia
Finally, run sudo apt update
to refresh cache.
Leave a Reply