Firebird News

Wednesday, November 28, 2007

Alternate way to compile AMR Codec Libraries for GNU-Linux into ffmpeg

This is a home page or amrnb and amrwb libraries, based on the reference implementation. I created it to prevent ugly embedding of the same code to many Open Source projects and to maintain patches and fixes for it.

Alternate way to compile amrcode libraries
is to download the scripts from bellow and then add the copile flags for ffmpeg from svn (or you can install it all in /usr and add no extra flags)
--enable-libamr-nb --extra-cflags=-I/opt/libamrnb/include --extra-ldflags=-L/opt/libamrnb/lib

http://ubuntuforums.org/showthread.php?t=178455


I will modify my compile scripts and see how it works
cat ffmpeg_checkout.sh
svn checkout svn://svn.mplayerhq.hu/ffmpeg/trunk ffmpeg
cat ffmpeg/configure.sh
./configure --prefix=/usr --enable-libamr-nb --enable-libamr-wb --enable-libogg --enable-libvorbis --enable-libgsm --enable-libxvid --enable-liba52 --enable-libmp3lame --enable-libx264 --enable-libtheora --enable-libfaad --enable-gpl --enable-shared --enable-pthreads --enable-swscaler
 cat mplayer_checkout.sh
svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer

mplayer is configured with --prefix=/usr

also don't forget to install the full code pack
http://www3.mplayerhq.hu/MPlayer/releases/codecs/all-20071007.tar.bz2
into /usr/lib/codecs

mkdir /usr/lib/codecs/
wget http://www3.mplayerhq.hu/MPlayer/releases/codecs/all-20071007.tar.bz2
tar -jxvf all-20071007.tar.bz2
cd all-20071007
mv * /usr/lib/codecs/

cd mplayer
./configure --prefix=/usr
make install
AMR Codec Libraries for GNU-Linux

Blogged with Flock

3 comments:

Mumble Bee said...

after following the steps from ubuntuforums lengthy tip..everything compiles ok..
but when i type mplayer in konsole..
mplayer: error while loading shared libraries: libamrnb.so.3: cannot open shared object file: No such file or directory

The author of this particular instruction says that it is due to being "--enable-shared --disable-static" switches not present..but i have followed instructions..

mariuz said...

you need to see where is libamrnb.so.3 and put in the path

see what ldd mplayer gives

mariuz said...

also you should configure libamrnb
with prefix=/usr and the type make; make install

http://www.penguin.cz/~utx/amr