RestrictedFormats

Revision 103 as of 2005-10-26 23:07:55

Clear message

Disclaimer and Legal Notice

Packages distributed in unofficial repositories are not supported by Ubuntu or Debian. Please don't file bugs caused by the use of third-party packages.

Some of the packages listed here may be illegal in your country. Use at your own risk.

Most of the formats listed here have been replaced by FreeFormats and this information is presented here for legacy and migration purposes. Be aware that the usage of non-free programs and formats cannot be supported because of the restrictions that affect them.

There are reasons why Ubuntu lacks media support for closed codecs "out of the box." A single example will be used- MP3's.

The group that holds the patent on MP3's demands that for each player with MP3 support a 75 cent fee must be paid: http://www.mp3licensing.com/royalty/index.html

It might not seem like a lot, but when the distro is free then even such a small fee is too much. The only other option is to pay a large one time fee that could otherwise pay a developer to work on Ubuntu for a whole year! So it costs money to distribute software that plays MP3s.

If Ubuntu ignored this, it could be sued in nations like the U.S. where this patent is valid. Either Ubuntu would have to pay up or the developers could never set foot in a country with such patent laws ever again (not reasonable). So because it costs money, Ubuntu has no MP3 support.

Now take this situation and multiply it times every type of restricted software out there (that isn't free like OGG), and you see what the situation is. So in order to spend money on developers, not laywers, Ubuntu has to avoid touching these codecs. Even an easier way to install them such as "click here to install" would make Ubuntu an accessory to a crime in many nations.

This is why it's important to support open codecs and standards. But Ubuntu can't provide restricted software or make it any easier because of the law.

Anchor(gettingstarted)

Getting Started

Ensure you have enabled both the Universe and Multiverse repositories before continuing. See AddingRepositoriesHowto for more information. Also, please read RootSudo if you are not familiar with using sudo.

Anchor(gettingcodecs)

Codecs

Some codecs are not distributed with Ubuntu for legal reasons. After reading and considering the disclamer and legal notice above, you may enter the following to install and enable the functionality:

We are going to use the debian-marillat repository to get the non-free codecs/plugins. Using your web browser, go to this directory on debian-marillat

ftp://ftp.nerim.net/debian-marillat/pool/main/w/w32codecs/

Alternatively download it from [http://www.giannaros.org/public/breezydebs/w32codecs_20050412-0.0_i386.deb here].

There will be one file with a .deb file extension there, this is the file we want. Save it in your home directory. Now, open a terminal prompt and go to your home directory. You should have only one w32codec debian package there. If you have more than one, you need to modify the next command to be more specific. For most users, just issue the following command:

sudo dpkg -i w32codecs_*.deb

Those using Kubuntu can also install akode-mpeg to enable MP3 playback.

Install and enable the packages that support the use of non-free codecs:

sudo apt-get install totem-xine gstreamer0.8-plugins gstreamer0.8-plugins-multiverse
sudo apt-get install msttcorefonts
gst-register-0.8

Anchor(gettingdvd)

DVD

Many DVD's use css, to play these discs a special library is needed. Due to legal problems it is not included with ubuntu, however it is capable of reading DVD's that are not encrypted. If it's legal for you to circumvent css, then you can use the following command to download and install libdvdcss to enable encrypted DVD playback functionality.

sudo /usr/share/doc/libdvdread3/examples/install-css.sh

To play these DVD's you would additionally need a player that uses libdvdread/libdvdcss such as totem-xine.

Anchor(dvdissues)

DVD Issues

If your video playback software (e.g. Xine, MPlayer, Totem, etc.) locks up when attempting to access a DVD, you will need to place a DVD movie in your DVD drive, then do the following:

sudo apt-get install regionset
regionset

If DVD playback is jerky or you notice optical data transfer (i.e burning a CD/DVD) is slower than it should be, then you need to enable DMA transfer for that drive. See the ["DMA"] page for details.

For backing up DVDs see ["DVDRippingandEncoding"].

Anchor(java)

Java

The easiest method is to use the Blackdown Java 1.4 installer from Multiverse. To install Java with the installer, just do:

sudo apt-get install j2re1.4

Ubuntu PPC, please see: ["JavaPPC"]. Ubuntu AMD64, please see: ["JavaAMD64"].

Sun Java

The alternative method which will get you the latest version from Sun and also works better for most applications is to install the Sun version of Java. Sun's implementation of Java and Java plugin for browsers is also non-free. Free Java is in active development and will be the preferred choice in the future also as a browser plugin (currently it is used in some programs like OpenOffice.org). Meanwhile, if you require Java support you have to install Sun's Java, assuming they happen to support your platform.

Go to http://java.sun.com/j2se/1.5.0/download.jsp and click on “Download JRE 5.0 Update 5”. Ensure you do not choose the link with the NetBeans bundle or "J2EE 1.4".

You must first accept the licence, then click on “Linux self-extracting file” (jre-1_5_0_05-linux-i586.bin). Save this file to your hard drive.

Make the downloaded file executable. At the command line, change to the directory where you downloaded the file, and type

chmod +x jre-1_5_0_05-linux-i586.bin

Install the java-package and java-common, as well as fakeroot (which allows a non-root user to create the package derived from Sun's bin file):

sudo apt-get install fakeroot  java-package java-common

If you get an error when installing java-package, you need to enable the multiverse repository (see ["AddingRepositoriesHowto"]).

To install JRE, run the downloaded file. Type

fakeroot make-jpkg jre-1_5_0_05-linux-i586.bin
sudo dpkg -i sun-j2re1.5_1.5.0+update05_i386.deb

make-jpkg translates Sun's bin file into a debian package. Then dpkg installs that package.

Sun Java SDK (Software Development Kit)

The same procedure can also be used to install Sun's Java SDK instead of just the runtime environment (JRE). Just choose "Download JDK 5.0 Update 5" when downloading the package from Sun, and replace the file name with jdk-1_5_0_05-linux-i586.bin

Selecting the default Java version

If you're running Breezy, you need to tell Ubuntu to use Sun Java instead of the open source GIJ included with it. Run:

sudo update-alternatives --config java

and select it from the list.

Java on Mozilla Firefox

Installing Java without following the previous steps does not alert Firefox to its presence. If you simply executed the .bin file you downloaded, you will need to tell Firefox or Mozilla where to find the plugin library:

If you do not have a .mozilla/plugins directory in your home directory, create one.

mkdir -p /home/username/.mozilla/plugins

Then

cd /home/username/.mozilla/plugins
ln -s /usr/local/jre-1_5_0/plugin/i386/ns610-gcc32/libjavaplugin_oji.so libjavaplugin_oji.so
sudo ln -s /usr/local/jre-1_5_0/plugin/i386/ns610-gcc32/libjavaplugin_oji.so /usr/lib/mozilla-firefox/plugins/

You can skip these steps if you used the make-jpkg command.

Anchor(realplayer)

Realplayer

Realplayer is the only legal MP3 player you can install in Ubuntu in nations where the format is restricted. An installer for an old version of realplayer is contained in the Ubuntu repositories. To install it just do:

sudo apt-get install realplayer

and follow the instructions.

Alternatively use the same approach as for the w32codecs package; go to:

ftp://ftp.nerim.net/debian-marillat/pool/main/r/realplay

And get the latest package (realplayer_10.0.6-0.0_i386.deb at the time of writing). Save it as before, open a terminal prompt, and go to the directory you saved the package in. Assuming there is only one realplayer debian package here just issue the following command:

sudo dpkg -i realplayer_*.deb

If you have downloaded more than one, you need to modify the command to be more specific.

Anchor(soundprob)

Sound Problems

Anchor(mp3ripenc)

MP3 Ripping and Encoding

  • ["CDRipping"]

MP3 decoding in K3b

Starting with Breezy (Ubuntu 5.10), K3B does not come with MP3 decoding support out of the box. Installing the k3b-mp3 package will enable it:

sudo apt-get install k3b-mp3

Anchor(mflash)

Macromedia Flash

Flash for i386

This will install the non-free Flash player and the plugins needed to view it in Firefox and Mozilla. If you have problems viewing text in some Flash files, you may need to install the msttcorefonts package, which is also in multiverse.

Note that this package doesn't exist for the amd64 architecture, as Macromedia has not yet produced a binary.

sudo apt-get install flashplugin-nonfree

After flash is installed, if the sound is not working properly, try typing the following in a terminal:

sudo ln -s /usr/lib/libesd.so.0 /usr/lib/libesd.so.1

A different try: create ~/.mozilla/firefox/rc with the line FIREFOX_DSP="none".

If you use an Intel 855GM video card, ensure you set the X server colour depth to 24 bits, otherwise you will probably experience Firefox crashes.

You may need to install the gsfonts-x11 package for flash to properly display fonts.

Flash for x86_64

For those of us with 64-bit processors (or Mac) there is no non-free flash implementation available because the manufacturer does not support them. However, there are two free implementations. One is gplflash and the other is swfdec. There's also gplflash2 in development that aims to be the proper free, open source replacement for all the platforms. While you can install them using apt-get, they tend not to work very well and are unstable, so that option is not great. Better to install one of them (I recommend gplflash) manually.

To install gplflash:

Download the latest version of gplflash (at the time of writing it was 0.4.13) from https://sourceforge.net/project/showfiles.php?group_id=110956.

$ wget -c http://prdownloads.sourceforge.net/gplflash/gplflash-0.4.13.tar.bz2?download

Sub in the latest version if it is no longer 0.4.13. Decompress the files.

$ tar xvjf gplflash-0.4.13.tar.bz2

Install software required to build gplflash.

$ sudo apt-get install build-essential libjpeg62-dev zlib1g-dev xlibs-dev libmad0-dev checkinstall

Change to the install directory.

$ cd gplflash-0.4.13

Compile the player and plugin, then call checkinstall to create a localised deb archive.

$ ./configure --prefix=/usr --with-plugin-dir=/usr/lib/mozilla-firefox/plugins/
$ make
$ sudo checkinstall

When checkinstall presents you with the overview, ensure you set option 7 (Architecture) to amd64 instead of x86_64. Then hit return to build and install gplflash-0.4.13_0.4.13-1_amd64.deb. Start mozilla or firefox and enjoy Smile :-)

Anchor(itunes)

AAC and iTunes Music Store

AAC decoding

The default audio format used by Apple's iTunes and iPod is AAC. This is a variant of the MPEG standard, and as such has patent issues. However, you can listen to AAC files in rhythmbox or amaroK by installing gstreamer0.8-faad. You will need this for listening to any AAC file, including those bought from the iTunes Music Store (see below for more info on using the music store on Linux). Warning: songs purchased from the iTunes music store (.m4p) are encrypted and will not just play using gstreamer0.8-faad. You will need to decrypt them first.

AAC encoding:

FAAC can be used to encode AACs, although this is somewhat experimental compared to MP3 encoding at this point. For encoding programs which use gstreamer, there is a gstreamer plugin called gstreamer0.8-faac. However, this currently is problematic, and does not produce usable AAC files, though this may change in the future.

For other programs, you may be able to utilize FAAC directly to encode to AACs - just install the "faac" package. You can make iPod-compatible AACs this way, but this requires some additional configuration in your CD ripping utility.

iTunes Music Store

Apple's iTunes Music Store sells music online with a large selection of artists. Songs are in 128K AAC format, and cost varies by country. Apple only has Mac and Windows clients, but it also can be used on Linux. There are two different methods by which this can be done.

First of all, you can use CodeWeavers CrossOver Office (available at http://www.codeweavers.com) to install the Windows version of iTunes on Ubuntu. This will allow you to buy iTunes songs on Linux and listen to them. However, the main caveats of this approach are that 1) it costs money 2) it is not a fully Linux-native solution.

As an alternative to using CrossOver, there is a new, Free program called PyMusique which allows basic usage of the iTunes Music Store on Linux. This works better than using iTunes on CrossOver, but PyMusique has fewer features than the official iTunes client at this point and may be in violation of the iTunes Music Store terms of service. To use this on Ubuntu, first install gstreamer0.8-faad and libmcrypt4. Then, go to http://fuware.nanocrew.net/pymusique/ or a mirror (google "pymusique 0.4" for mirrors) and download the pymusique, python2.4-mcrypt, python2.4-vlc, and python2.4-mp4ff packages. Finally, install all the packages you downloaded from the above website. You can now launch PyMusique from the Applications-Internet menu, and purchase songs (although you may have to restart your system for this to work).

PyMusique has been superceded by SharpMusique, available from http://www.nanocrew.net/software/sharpmusique/. It's available as a .deb for Breezy Badger and allows you to preview songs, signup for an account, buy songs and albums, redownload songs that you bought, and more.