LAME MP3

From Audacity Manual

Jump to: navigation, search
When you first obtain Audacity, it normally cannot export MP3 files. This is because the necessary LAME MP3 encoding technology is patented, and so Audacity as a free, open source program cannot distribute it. However Audacity can use the LAME encoder if you download it separately yourself (or if it's already present on your computer) and make sure Audacity knows where it is.

Disclaimer

While the LAME encoder itself and its source code are free, in some countries you may need to pay a licence fee to legally encode MP3s, because of the patented technology the encoder uses. Individuals must decide for themselves whether they should use LAME for free, according to the country they are in and their own conscience.


Locate LAME dialog

Locate Lame dialog
If you try to export an MP3 and Audacity cannot find the LAME encoder, it will pop up a dialog asking for LAME's location. This example (right) is on a Windows computer, on which the LAME file needed is called "lame_enc.dll". If you know where a copy of the required LAME file might be on your computer:
  1. In the Locate LAME dialog, click "Browse..."
  2. In the file browser that pops up, navigate to the LAME file, select it and click "Open"
  3. In the Locate LAME dialog, click "OK" - you can now export your MP3 file

The "Locate LAME" dialog is also accessible by clicking Locate... in the "MP3 Export Library" section of the Libraries Preferences.

If you don't know where to find LAME, or don't think you have it on your system, follow the Windows, Mac or Linux/Unix instructions below to download and install it.


Windows instructions

It's possible other programs on your computer may already have installed "lame_enc.dll" in locations where Audacity can find it automatically. So if you've not already done so, try exporting an MP3 by clicking File > Export... . Then choose "MP3 Files" in the "Save as type" box, choose your file name and click "Save". If Audacity can't find LAME, you will see the "Locate Lame" dialog as above.
  1. In the Locate LAME dialog, click the "Download..." button
  2. On the web page that appears, go to the "Windows" section and click the link "LAME download page"
  3. Under "For Audacity on Windows", left-click the link libmp3lame-win-3.98.2.zip; alternatively, click here to download the file directly Note: don't right-click either link, and do not open the file, but save it to any location on your computer
  4. Extract the file lame_enc.dll from the zip to a location of your choice - we recommend the Desktop, or your Audacity installation folder, which is normally at C:\Program Files\Audacity
  5. If you need an unzip application, try 7-zip
  6. Return to the Locate LAME dialog, click "Browse...", navigate to the folder where you put the unzipped "lame_enc.dll" file , and select it
  7. Click "Open", then in the Locate LAME dialog, click "OK". Now your MP3 will export.
  8. In the event of download problems, use this alternative download link.
As an even easier alternative, click here to download an already unzipped copy of lame_enc.dll. Do not open it, but simply save it to any location on your computer. Then follow steps 6 to 8 above.


Mac instructions

  1. Click Audacity > Preferences, then the LIbraries tab, and in the "MP3 Export Library" section at the top, click the "Download..." button (if you have already tried to export an MP3, click the "Download..." button in the "Locate LAME" dialog)
  2. On the web page that appears, go to the "Mac OS 9 or X" section and click the link "LAME download page"
  3. Click the download link Lame Library v3.98.2 for Audacity on OSX.dmg; alternatively, click here to download the file directly Note: don't control-click either link
  4. When you have finished downloading, double-click the .dmg to mount it, then go to the Finder (in Safari, "Lame Library v3.98.2 for Audacity.pkg" will be extracted automatically after downloading).
  5. Double-click "Lame Library v3.98.2 for Audacity.pkg". This will install the LAME binary "libmp3lame.dylib" in /usr/local/lib/audacity
  6. Click "OK" to exit Preferences (to complete export of an MP3, click "Browse..." in the "Locate LAME" dialog, navigate to /usr/local/lib/audacity, select "libmp3lame.dylib", click "Open", then "OK")
  7. In the event of download problems, use this alternative download link.

Linux/Unix instructions

  1. Check in the repositories for your distribution if a pre-compiled LAME package is available (it would probably be called LAME or LAME_ENC). If so, download and install the package. Otherwise, download LAME from its home page and compile it as a shared object.
  2. In the Locate LAME dialog, click the "Browse" button. If the dialog is not visible, click Edit Menu > Preferences and click the Libraries Preferences tab. In the "MP3 Export Library" section at the top, click the "Find Library" button, then "Browse".
  3. In the file browser, locate the file libmp3lame.so.0 (usually it will be in /usr/local/lib) and select it. If you have installed a software development package or compiled LAME from source, the file will be called libmp3lame.so - in that case, ignore any warning that Audacity gives and select the file anyway.
  4. Click Open, then in the Locate LAME dialog, click OK. Now your MP3 will export.


Troubleshooting: If Audacity still pops up the "Locate Lame" dialog when you try to export MP3, then either you haven't unzipped or expanded the LAME file properly, or you saved it to the wrong location. Go through the instructions above again, downloading a fresh copy of the file if necessary.

You can find out the LAME library Audacity is using at any time by going to the Libraries of Preferences. The "MP3 Library Version" will be stated, or you can access buttons to locate the LAME library or re-download it.

If you need more help, go to our Wiki page on LAME installation and look at the section for your particular operating system.
Views
Help Location