Almost every desktop *nix seems to ship without support for MP3 or other popular codecs that you really need.
What is the easiest way to add support for these codecs?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.
Sign up to join this communityAlmost every desktop *nix seems to ship without support for MP3 or other popular codecs that you really need.
What is the easiest way to add support for these codecs?
Our *nix's always recommend free formats over the restricted ones... see the Ogg Vorbis format (lossy) or FLAC (lossless). But if you must have your non-free format supported here are guides for a few *nixs
Ubuntu has a detailed guide for installing restricted formats. In particular for recent Ubuntu versions it is as simple as opening the Terminal, and executing the following command:
sudo apt-get install ubuntu-restricted-extras
OpenSuse has a page on restricted formats and links to a 5 minute solution to MP3 support that shows you how to install the Fluendo MP3 decoder.
On LinuxMint install the "Codec MP3 Encoding" mint file and you should have MP3 support in SoundJuicer.
Fedora only supports MP3 through third party repositories. And also has a guide to installing Fluendo.
The OpenBSD FAQ recommends installing LAME and states that "Lame is included in the OpenBSD ports tree."
There are some Linux distros like Slackware that include MP3 support by default.
In Debian based distributions, such as Ubuntu, you first have to enable their non-free package repositories through your-favorite-package-manager.
In synaptic
open Settings > Repositories and make sure all boxes are checked.
In apt-get things are a bit more tricky. You'll have to track down the URL for your distro's non-free repository and add it to your /etc/apt/sources.list
.
Then install your-favorite-mp3 lib, or simply reinstalling your-favorite-media-player. If that doesn't work, just install VLC, any other media players you have running should pick up and run with the mp3 libraries it depends on.
The mp3 codec is patented through Fraunhoffer AG in the United States (Patent 5,579,430). Deployment of a decoder requires a very small royalty be paid to Fraunhoffer for use of mp3 tech. Use of the codec without payment subjects the creator(s) of the installation to the liability of patent infringement.
For paid *nix installs, this shouldn't be a problem; it's assumed it will be included in the price.
For free *nix installs, this can be toxic to ship in a "official" manner. Being a "free" install, there would be a burden to cough up royalty money every time someone did a download. Kinda makes it difficult to be "free".
Expect answers to differ on how to best approach this. The free installs tend to take the "not here, go over there, nudge nudge wink wink" approach. There is typically a repository that is "unofficially" maintained by volunteers (always in a country where the patent doesn't apply), which you will need to enable in your local installation to gain access to. Visiting the website or FTP directory for these repositories usually shows an up-front disclaimer that states "If you're in a country that has patents on mp3 tech, you are liable for use of these, yada yada..."
If there is no repository system (such as apt-get
or yum
) then you're left to your own devices to download the required binaries and/or source, and install them. One such installation would be LAME, which also provides an mp3 encoder.
Debian's approach is rather novel; they ship the toolame library, which uses the non-patent-encumbered mp2 (mpeg audio layer 2) format, which was a precursor to mp3 (mpeg audio layer 3). The advantage to this is that the file format works interchangeably with mp3 players, without any effort or incompatibility. The disadvantage of this is that mp2's are not as well-compressed, so the files tend to be about 10% larger than the same audio compressed as an mp3. Unfortunately, toolame never really seemed to catch on..
Unfortunately, I think this is likely to be very distro specific; in general there's probably a package in your package manager that provides the capability, you just have to figure out what the name of it is
On Gentoo there are global use flags:
mp3
-- Causes a package to depend on media-sound/lame
for MP3 encodingmad
-- Causes a package to depend on media-libs/libmad
for MP3 decoding