debian5编译安装 ffmpeg

 

添加媒体源

deb http://www.debian-multimedia.org lenny main non-free
deb ftp://ftp.debian-multimedia.org lenny main non-free
 

添加需要的包

apt-get install libfaac-dev libmp3lame-dev libtheora-dev libvorbis-dev checkinstall texi2html libfaac-dev 
apt-get install libsdl1.2-dev libtheora-dev libvorbis-dev libx11-dev libxfixes-dev libxvidcore-dev zlib1g-dev
apt-get install libpng12-dev libpng12-0
apt-get install git git-core
 
 

以下三个包需要通过源码装

wget http://downloads.sourceforge.net/project/opencore-amr/opencore-amr/0.1.2/opencore-amr-0.1.2.tar.gz?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fopencore-amr%2F&ts=1285256783&use_mirror=ufpr
wget http://webm.googlecode.com/files/libvpx-v0.9.7-p1.tar.bz2
 

安装最新的YASM不然x264编译不过

apt-get remove yasm
http://www.tortall.net/projects/yasm/releases/yasm-1.1.0.tar.gz
 

安装最新的x264

apt-get remove x264 x264-dev
git clone git://git.videolan.org/x264.git
./configure --enable-shared
make && make install
 

安装FFMPEG

wget http://ffmpeg.org/releases/ffmpeg-0.8.5.tar.bz2
./configure --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libxvid --enable-x11grab --enable-filter=movie --enable-libx264 --enable-avfilter
 make && make install

#error while loading shared libraries: libavdevice.so.52: cannot open shared object file: No such file or directory

解决方法:

vi /etc/ld.so.conf

添加一行 /usr/local/lib

执行 ldconfig
 

参考

 
http://www.staroceans.net/ffmpeg.html
http://www.lvdanjiang.com/index-view-197.html
http://zfl110.iteye.com/blog/1161681
http://hi.baidu.com/717869/blog/item/cabb434e258c64ced0c86a2d.html
http://blog.sina.com.cn/s/blog_3cb6a78c0100vupy.html

上一篇: ostube错误调试总结   下一篇: FFmpeg给FLV文件加水印

提交疑问

回顶部