Page 2 of 3
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Sun Dec 21, 2008 6:56 pm
by Gale Andrews
It looks like you got over the aclocal problem? Some people do have problems because aclocal is by default installed in /usr whereas pkg-config is installed in /usr/local, $HOME/local or elsewhere. So when aclocal is run, it only searches in /usr/share for .m4 files to expand. See
this thread for details.
Have you tried building from CVS using Xcode?
Using the Xcode project files does work (including building sbsms), and we now have Mac
nightly builds working again built using Xcode. But command line building may not work without expert knowledge and workarounds.
If you still have issues, I would suggest
subscribing to the audacity developers' list and post there.
Gale
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Mon Dec 22, 2008 9:57 am
by DrGlitch
Thanks for the info about aclocal Gale. I'm unfamiliar building in Xcode and I wanted to build Audacity with FFMpeg. This is why I was attempting to do so via the command line.
However, I did give building in Xcode a shot. I used the latest beta source for audacity (cvs -d:pserver:
[email protected]:/cvsroot/audacity checkout audacity) and tried building Release Shared. It got errors compiling Resample.cpp as it could not find samplerate.h. I determined that I needed to add $(TOPLEVEL)/lib-src/samplerate/src to the User Header Search Path. This fixed the problem, and then I get the following error Linking Audacity:
i686-apple-darwin8-g++-4.0.1: /usr/local/lib/libwxregexud-2.8.a: No such file or directory
i686-apple-darwin8-g++-4.0.1: /usr/local/lib/libwxexpatd-2.8.a: No such file or directory
i686-apple-darwin8-g++-4.0.1: /usr/local/lib/libwxtiffd-2.8.a: No such file or directory
i686-apple-darwin8-g++-4.0.1: /usr/local/lib/libwxjpegd-2.8.a: No such file or directory
i686-apple-darwin8-g++-4.0.1: /usr/local/lib/libwxpngd-2.8.a: No such file or directory
I do have libraries with these names without the "d" in /usr/local/lib. For example /usr/local/lib/libwxregexu-2.8.a. Possibly just a naming error? Also it is not obvious how these are specified to be linked into Audacity in Xcode. They are not in the "Link Library With Binaries" list for the Audacity target.
Maybe I should try the latest Mac nightly build instead of the latest directly from CVS. If I still have issues, I'll jump onto the developer's list and start a new topic there.
Thanks again,
Rich
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Tue Dec 23, 2008 9:09 am
by Gale Andrews
The suffixes (or not) such as "d" would I imagine represent the configuration of Widgets that was built, but I can't help you beyond that as I'm on Windows. Anyway, FFmpeg should be "on" in the nightly builds and we do now have our
FFmpeg binary for Mac available.
Gale
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Wed Dec 24, 2008 12:34 am
by DrGlitch
I guess I should have been more specific regarding FFmeg. I want to export using the FFmpeg aac format.
I downloaded the latest nightly build and installed the FFmpeg binary. Audacity now gives me the option to Export using "M4A (AAC) Files (FFmpeg)", but this results in the following error: "FFmpeg cannot find audio codec 0x15002. Support for this codec is probably not compiled in."
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Wed Dec 24, 2008 7:47 am
by Gale Andrews
DrGlitch wrote:I downloaded the latest nightly build and installed the FFmpeg binary. Audacity now gives me the option to Export using "M4A (AAC) Files (FFmpeg)", but this results in the following error: "FFmpeg cannot find audio codec 0x15002. Support for this codec is probably not compiled in."
I'll see if anyone can reproduce this. But meantime are you sure Audacity is using the libraries you downloaded and not the copy you built or some other one and getting tangled? The only way to be sure of the correct library is used is either not have environment variables for dynamic library loading, or arrange them to pick up /usr/local/lib/audacity (where the library Audacity wants is).
Gale
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Wed Dec 24, 2008 8:40 am
by DrGlitch
I don't believe it is getting the incorrect lib. In this case, since I downloaded the Audacity executable, I am launching it from the Applications directory and not executing it in a shell. I don't think environment variables can be set for the Launcher. When going into Preferences>"Import / Export" and selecting "Find Library" for FFmpeg, the location of libavformat.52.dylib is shown as /usr/local/lib/audacity/libavformat.52.dylib.
The displayed FFmpeg Library Version is F(52.23.1),C(52.8.0),U(49.12.0)
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Thu Dec 25, 2008 1:14 pm
by Josh24
Dr G-
It sure sounds like the ffmpeg libraries Leland made available were built without Faac and Faad enabled. Those two libraries need to exist in usr/local/lib before ffmpeg is compiled using `./configure --enable faac --enable faad ...` Same with AMR support, libamr-nb and -wb are built first. Then when Audacity is built --with-ffmpeg support all those import/export options will work, as well as AC3, which is built-in to ffmpeg. Didn't you compile your own fflibs earlier? If you did, and have faac,d installed also, you could switch them into lib/audacity and see what happens. You can play with comparing the library binaries with `nm` command. It will show what objects are embedded in the dylib, you can see if libavcodec has faac linked.
Josh
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Thu Dec 25, 2008 8:15 pm
by Gale Andrews
Josh24 wrote:Dr G- It sure sounds like the ffmpeg libraries Leland made available were built without Faac and Faad enabled. Those two libraries need to exist in usr/local/lib before ffmpeg is compiled using `./configure --enable faac --enable faad ...` Same with AMR support, libamr-nb and -wb are built first. Then when Audacity is built --with-ffmpeg support all those import/export options will work, as well as AC3, which is built-in to ffmpeg. Didn't you compile your own fflibs earlier? If you did, and have faac,d installed also, you could switch them into lib/audacity and see what happens. You can play with comparing the library binaries with `nm` command. It will show what objects are embedded in the dylib, you can see if libavcodec has faac linked.Josh
Leland confirms he did only include the GPL (General Public License) libraries, so excluding libfaac. This was a mistake, because LGPL (Lesser General Public License) libraries like libfaac can legitimately be included in a GPL application like Audacity and then become GPL licensed. The installer available at:
http://www.audacityteam.org/manual/inde ... -Ins#macff
is now updated to include libfaac and other LGPL libaries.
However, AMR support is not available in that installer (assuming he built it correctly), and never will be, because AMR support cannot be legally distributed. If you want AMR support, you would have to link Audacity with a libamr-enabled FFmpeg library that you compiled yourself.
Gale
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Thu Dec 25, 2008 9:55 pm
by DrGlitch
Checking the FFmpeg libs using nm shows no references to libfaac_encoder or libfaad_decoder. So you are correct that the FFmpeg Libraries for Audacity.pkg were made without Faac and Faad.
I did try putting faac and faad libraries into /usr/local/lib/audacity with no effect. However what did work was putting the FFmpeg libs that I built with faac and faad into the audacity directory. I then set the Preferences>"Import / Export" for FFmpeg to point to my copy of libavformat and Audacity now exports M4a (aac) format properly.
Hopefully future builds of the FFmpeg Libraries for Audacity.pkg will include Faac, Faad, and Amr.
One more question. Should any bugs I find be posted here, or to the audacity developers list?
Re: Building with FFMPEG - LIBSNDFILE not available
Posted: Fri Dec 26, 2008 3:01 am
by Gale Andrews
DrGlitch wrote:...what did work was putting the FFmpeg libs that I built with faac and faad into the audacity directory. I then set the Preferences>"Import / Export" for FFmpeg to point to my copy of libavformat and Audacity now exports M4a (aac) format properly.
Glad that works as expected.
DrGlitch wrote: Hopefully future builds of the FFmpeg Libraries for Audacity.pkg will include Faac, Faad, and Amr.
The current FFmpeg Libraries for Audacity.pkg should import and export AAC, as stated in my post above. As I also stated, we will not support the current AMR code. This is because 3GPP supply it under a non-redistributable licence. Therefore for now, you need to install libamr and compile FFmpeg with libamr enabled. FFmpeg are I gather working on a native implementation of AMR, and obviously if/when that comes out, it will be distributable.
DrGlitch wrote:Should any bugs I find be posted here, or to the audacity developers list?
Neither. Bugs should please be sent to feedback_AT_audacityteam_DOT_org stating your operating system and version of Audacity.
Gale