HOW TO: Install libx264 and libmp3lame

Created by Jonathan Thomas
Keywords:
libx264 libmp3lame export error
Last updated by:
Olivier Girard

Many of the export presets in OpenShot use h.264 and/or mp3 codecs. If you do not have the correct packages installed on your system, these codecs will not work, and instead of exporting your video, OpenShot will show an error message saying, "The following formats/codecs are missing from your system: libx264 and libmp3lame".

NOTE: The follow package is installed with OpenShot: libavformat. Ubuntu and Debian have 2 versions of this package, one that is restricted (or stripped), and one that is unrestricted (or unstripped).

Note of 1 st december 2014 : Medibutnu is dead, use Sven PPA
Note of 30 June 2015 : For 14.04/ LInux Mint 17.x users, you must use the following ppa : https://launchpad.net/~mc3man/+archive/ubuntu/trusty-media

To fix this problem in Ubuntu / Debian, use the following steps:

Step 1) Open Synaptic Package Manager
Step 2) Search on "libavformat"
Step 3) We need to install the alternate version of libavformat... the one with h.264 and mp3 codecs. These package names vary from distribution to distribution, but it should be something similar to:
  a) libavformat-extra
  b) libavformat-unstripped
Step 4) Close and re-launch OpenShot. You should now be able to use libmp3lame, h.264, and many other restricted formats.

If you have trouble finding the correct package name, just google "libavformat" and the name of your Linux distribution. Good luck!

Note from July 2011:
This version is also available by activating the Medibuntu repository.
Here (http://openshotusers.com/forum/viewtopic.php?f=12&t=914) is an explanation on How to activate this repository on Natty.

Note from January 2012:
This version is also available by activating the Medibuntu repository.
Here (http://openshotusers.com/forum/viewtopic.php?f=12&t=1053) is an explanation on How to activate this repository on Oneiric.

Note from May 2012:
This version is also available by activating either the Medibuntu repository either the sven PPA.
Here (http://openshotusers.com/forum/viewtopic.php?f=12&t=1261) is an explanation on How to activate this solution on Precise.