How to add MP3 support to your Linux Distribution?
June 21, 2006
ProblemYou've just installed a new Linux distribution on your computer and it won't play your MP3 files? All your songs are encoded in that format and you don't know what to do? Well, don't worry. This is a common problem in Linux and it has a simple solution.
ReasonYou might wonder why these distributions decided not to include mp3 support. After all, mp3 is one of the most widely used format to encode music and a lot of people like to copy their songs from their mp3 players to their computer and vice versa. Since so many people use MP3 it seems unreasonnable not to include it in the distribution.
"Imagine that each time you made a software design decision, and especially whenever you used an algorithm that you read in a journal or implemented a feature that users ask for, you took a risk of being sued. That's how it is today in the US, because of software patents. Soon it may be the same in most of Europe [...]
In the US and some other countries, free software for MP3 is impossible; in 1998, US developers who had developed free MP3-generation programs were threatened with patent lawsuits, and forced to withdraw them. Some are now distributed in European countries -- but if the European Patent Office makes this planned change, they may become unavailable there too. [...]
Copyright 1999 Richard Stallman
Verbatim copying and redistribution of this entire article is permitted provided this notice is preserved."
Ubuntu justifies their choice by saying:
"Ubuntu strives to make every piece of software available under the licensing terms laid out in the Ubuntu License Policy. Patent and copyright restrictions complicate a free operating system's ability to distribute software that will support proprietary or non-free formats. Because of its commitment to only include completely free software by default, Ubuntu does not support proprietary media formats 'out of the box'."Fedora says:
"MP3 encoding/decoding support is not included in any Fedora application because MP3 is heavily patented in several regions including the United States. The patent holder is unwilling to give an unrestricted patent grant, as required by the GPL. Other platforms might have paid the royalty and/or included proprietary software. Other Linux distributions not based in a region affected by the patent might ship MP3 decoders/encoders or they might have included proprietary software. However, Fedora Core cannot and does not ship MP3 decoders/encoders in order to serve the goal of shipping only free and open source software that is not restricted by software patents."
General SolutionThe best solution is to avoid using MP3 altogether. There are other formats which are free and also more efficient than MP3 at encoding audio files. The most popular of them is called OGG Vorbis.
Add MP3 support in Ubuntu 6.06 - Dapper DrakeIn Ubuntu 6.06, make sure you added the Universe and Multiverse repositories and install the package gstreamer0.10-plugins-ugly.
Add MP3 support in Fedora Core 5
Make sure you added the LIVNA repository. Then, depending on your players:
Add MP3 support in SUSE 10.1
For xine-based players (e.g. amarok, if you have the package "amarok-xine" installed
and selected the "xine" engine in its configuration, which is highly recommended
anyway), you should add the Packman  repository to your list of installation
sources and install the package "libxine1".
For MP3 support in k3b, the popular CD/DVD burning application, upgrade to the latest k3b version from the Packman repository and install the package "k3b-mad".
Last but not least, also add the Guru  repository to your list of installation sources and install the "libtunepimp-mad" and "libtunepimp-faad2" packages. Note that you'll also find the latest amarok version in the Guru repository, amongst others.
Note: Thanks to Pascal for this solution (see comments).
Your player probably DOES support Ogg Vo
June 22, 2006"your MP3 player probably doesn't support OGG"
June 23, 2006
2006-06-23Yes, I was referring to MP3 player devices. For instance, the one I have is an i-bead 100 and it doesn't support OGG by default. It is also hard to find a firmware for it that would support OGG as the performance of the player itself are not good enough to decompress this format.
Eventually I'll have to buy a new portable player, but until them I can't really convert my music files to OGG. I'm stuck :)
Information not accurate for SUSE Linux
By Pascal Bleser
June 25, 2006Good writeup, especially on the patents, but unfortunately the information for SUSE Linux is not correct: the w32codec-all package has nothing to do with MP3 de/encoding (it's actually for proprietary video codecs for MPlayer, xine, kaffeine, ...).
June 25, 2006Bonjour Pascal,
Copyright 2006 http://linuxmint.com/