Ubuntu 14.04 & Audacity

Hey, whats wrong with this? When I Install the new distribution of Ubuntu and Audacity 2.0.5. Audacity sudenly doesn’t allow to import AAC nad MP4 files anymore. Whithout this option it’s useles for me. The program doesn’t allow to instal LAME and FFmpeg from it’s edit>settings>libraries menu. I have knowledge, that you know about the problem, so why don’t you do something about it? What can I do by myself about it?

Audacity 2.0.5 does support Ffmpeg (required for M4A support) but Audacity must be built with Ffmpeg support enabled. We do not build Audacity for Ubuntu, we just provide the source code and they configure and build Audacity as they see fit. As this issue is with Ubunu 14.04 beta you should report the issue to Ubuntu.

Thanks alow forum the answer, I Will talk with them them.

It seems there is a problem because Audacity supports old FFmpeg and does not compile against libav which comes with latest distributions.

There is a bug report which is was reported almost 2 years ago: https://bugs.launchpad.net/ubuntu/+source/audacity/+bug/1076928

Also on Audacity bug reports: http://bugzilla.audacityteam.org/show_bug.cgi?id=540

So I guess Audacity team didn’t do anything by now? My company uses Audacity a lot and I was so happy when 14.04 came out so we can upgrade and then I cold shower: Audacity does not import anything we need it for :frowning:

FFmpeg is an optional add-on and not part of the distributed Audacity program.
While I agree that it is more convenient to be able to import closed format files directly into Audacity, being able to do so is not essential to the correct functioning of the Audacity program. We have no control over which version of external libraries are used by Linux distributions. Audacity currently supports building against FFmpeg 0.5 through 0.8.

No doubt ffmpeg/libav support will be updated eventually, but Audacity is created and supported by volunteers. We don’t have the resources to accomplish everything that we would like to. If your company has software developers that are able to assist with this (rather complex) upgrade, patches may be submitted to the developer’s mailing list: http://audacityteam.org/community/developers

The most simple workaround is to convert your files to a supported format before importing into Audacity. Ubuntu includes tools for doing this.
For exporting, Audacity allows the use of external command line encoders (see: http://manual.audacityteam.org/o/man/exporting_to_an_external_program.html)

If your company is committed to using open source software, then it may be a good idea to investigate the possibility of using open formats such as WAV, Flac, Ogg, Speex, etc. rather than closed / proprietary formats that are problematic (for legal and ethical reasons) for open source programs to support.

Steve, I know it’s all optional and I appreciate your hard work. But sadly we are not in position to tell what recordings format should be sent to us. We are press agency and we have to edit and convert whatever comes our way. There are no legal or ethnical reasons. It’s the same as we have to open documents with press material sent in different formats. Senders never asked if we can open it or not. We ditched windows 4 years ago because we could manage everything with open source tools and operating systems and now we hit the wall. Actually I did. Because I’m responsible for switching to open source. Sadly I’m not a developer so I can’t help with patches, but I have to find the way to make it work.

Steve told you how to make it work. For example, open a terminal:

ffmpeg -i client.m4a client.wav

This will take the file “client.m4a” in your home folder and produce a file “client.wav” in the same folder. If the client.m4a is somewhere else, give the full path to the file in quotes.

Can you describe the problem in more detail?

Are you saying the packaged build of Audacity that comes with Ubuntu 14.04 does not have FFmpeg support? Is there a “Libraries” section at Edit > Preferences… ? What error is given when you drag the M4A file in? Please also post the log from Help > Show Log… after importing the file.

Please see here for how to attach files: https://forum.audacityteam.org/t/how-to-attach-files-to-forum-posts/24026/1 .


I thought this was just a problem with Ubuntu 14.04 Beta, but from a quick search, it appears Canonical have compiled the Audacity package that comes with 14.04 without FFmpeg support. The inferences made are that it is too difficult to maintain a separate very outdated libav just for Audacity.

So, another answer is to uninstall the Audacity package, compile FFmpeg 0.8 and self compile the 2.0.5 source tarball against the older FFmpeg.


I managed to build custom FFmpeg 0.8.6 and compiled Audacity to work with it.

Most of the time I had no idea what I was doing and I was following these pages:

After I had working FFmpeg, I didn’t know how to make Audacity work with it so I made some corrections to those instructions and built shared library:

./configure --prefix=“$HOME/ffmpeg_build” --bindir=“$HOME/bin” --enable-shared

./configure --prefix=“$HOME/ffmpeg_build” --extra-cflags=“-I$HOME/ffmpeg_build/include” --extra-ldflags=“-L$HOME/ffmpeg_build/lib” --bindir=“$HOME/bin” --extra-libs=“-ldl” --enable-gpl --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-x11grab --enable-shared

After that, I was able to select libavformat.so.53 from ffmpeg_build/lib folder. I tested with some AAC audio file and it worked.

Well done.

Yes FFmpeg must be configured with --enable -shared so that it builds the shared object library (.so) file that Audacity Libraries Preferences is looking for.

As far as I know, --enable-libx264 is not needed for Audacity as that is a video encoder.

If you are encoding AAC/MP4 with Audacity, I suggest you check the quality, as the native FFmpeg AAC encoder was not very good with FFmpeg 0.6 and I don’t know if that was resolved by 0.8.

Certainly for FFmpeg 0.6 the general recommendation was to configure FFmpeg with

--disable-encoder=aac --enable-libfaac

Note that libfaac (at FFmpeg 0.6) has an issue not present in the native FFmpeg encoder that saved files are short at the end by about 3000 samples.


Thank you Gale for tips. I hope those things gets resolved also with proper packaging so it’s somehow included for easy installation.

Audacity Packages and what libraries are compiled in are solely the responsibility of the distribution.

As I’ve said before elsewhere, I think endlessly patching Audacity to keep up with frequent FFmpeg changes for dynamic library loading is misguided. It would be much better for Audacity to provide a GUI for FFmpeg import and export leveraging the FFmpeg binary - then any reasonable version of FFmpeg would work with Audacity.


I checked FFmpeg downloads. According to Audacity, it supports versions between 0.6 and 0.8? So the last 0.8.9 should be ok?

I think you would have to try it, or pore over the release changelog for the FFmpeg version. Some people have claimed Audacity accepts some 0.9x versions but not others.


I agree that it would be a good long-term solution to be able to use an FFmpeg binary when importing.
Audacity’s “Export audio → external program” does this job well when exporting. :sunglasses:

andrew.46 has done some work to have Audacity use a local FFmpeg library with Ubuntu-14.04.

(I chose to build a library for import only, and use “Export audio → external program” for exports). :sunglasses:

The thread is here —> http://ubuntuforums.org/showthread.php?t=2219907

Thanks for information and the link bat999.
I’ll add a note in our documentation.

[Update: Note added here: http://wiki.audacityteam.org/wiki/Compiling_Audacity_for_Beginners#Example_compiling_the_latest_Audacity_source_code_on_Ubuntu_and_derivatives_.28like_Linux_Mint.29]

For those not interested in building & desiring dynamic loading then you may try this ppa.
As it is a dynamic loading build you must also manually install the 3 ppa ffmpeg packages & then set up once in audacity > Edit > preferences > Libraries
(just read the instructions on ppa main page.
It would be possible to not use dynamic loading like Ubuntu typically did but atm not inclined to do that way.

Any configuration changes to audacity or ffmpeg that would be beneficail can be relayed to me via launchpad email.

A patched audacity will be available shortly for 14.04 & 14.10. The 14.04 build will use libav9, the 14.10 possibly will be using libav10 (patches also allow the use of FFmpeg > 1.2
For 14.04 it will first show in -proposed, look for 2.0.5-1ubuntu3.2, the current one, 2.0.5-1ubuntu3.1, needed fixing which has been done but not yet built

I am not clear if you are talking about your builds or not, but as I assume you know, it’s now possible to build latest Audacity source code with theoretical support for FFmpeg 2.2.x and libav 0.8 with default ./configure. There may still be problems if you compile against system libav unless you use

./configure --disable-dynamic-loading