ffmpeg完全安装
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
Linux下ffmpeg的完整安装:
首先安装各种解码器
1.安装MP3音频编码器lame
lame-398-1.tar.gz
Url:/project/showfiles.php?group_id=290&package_id=309
tar zxvf lame-398-1.tar.gz
cd lame-398-1
./configure --enable-shared --prefix=/usr
make & make install
2.安装汇编优化器yasm,可能安装x264要用到
/projects/yasm/releases/
tar zxvf yasm-1.3.0.tar.gz
cd yasm-1.3.0
./configure --enable-shared --prefix=/usr
make & make install
3.安装ogg库,libogg
Url:/releases/ogg/libogg-1.3.2.tar.gz
tar zxvf libogg-1.3.2.tar.gz
cd libogg-1.3.2
./configure --enable-shared --prefix=/usr
make & make install
4.安装vorbis编解码器,libvorbis
Url:/releases/vorbis/libvorbis-1.3.3.tar.gz
tar zxvf libvorbis-1.3.3.tar.gz
cd libvorbis-1.3.3
./configure --enable-shared --prefix=/usr
make & make install
/*********************************这里是分隔符**************************/
出错提示: *** Could not run Ogg test program, checking why... *** The test program compiled, but did not run. This usually means *** that the run-time linker is not finding Ogg or finding the wrong *** version of Ogg. If it is not finding Ogg, you'll need to set
your *** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point *** to the installed location Also, make sure you have run ldconfig if that *** is required on your system *** *** If you have an old version installed, it is best to remove it,
although *** you may also be able to get things to work by modifying LD_LIBRARY_PATH configure: error: must have Ogg installed!
解决:
# vi /etc/ld.so.conf
include /etc/ld.so.conf.d/*.conf
/usr/local/lib
# ldconfig –v
5.安装x264编码器的库,x264-snapshot
Url:/developers/x264.html
ftp:///pub/videolan/x264/snapshots/
tar xvf last_x264.tar.bz2
cd x264-snapshot-20141218-2245/
./configure --enable-shared --prefix=/usr
make & make install
6.安装xvid编码器,xvidcore
Url:/downloads/xvidcore-1.3.2.tar.gz
tar zxvf xvidcore-1.3.2.tar.gz
cd xvidcore/build/generic/
./configure --prefix=/usr
make & make install
7.安装dts库,libdca
Url: /developers/libdca.html
tar xvf libdca-0.0.5.tar.bz2
cd libdca-0.0.5
./configure --enable-shared --prefix=/usr
make & make install
8.安装a52,a52dec
/downloads.html
tar zxvf a52dec-0.7.4.tar.gz
cd a52dec-0.7.4
./configure --enable-shared --prefix=/usr
make & make install
如果出现
---------------------------------------
./configure
make
/usr/bin/ld: .libs/imdct.o: relocation R_X86_64_32S against `a local symbol’ can not be used when making a shared object; recompile with -fPIC
.libs/imdct.o: could not read symbols: Bad value
collect2: ld returned 1 exit status
make[1]: *** [] Error 1
make[1]: Leaving directory `/home/buynintw/src/a52dec-0.7.4/liba52′
make: *** [install-recursive] Error 1