記錄一下成功安裝ffmepg在EC2的步驟。
1. 首先建立ffmepg資料夾
$cd /usr/local/bin/
$sudo
mkdir ffmpeg
$cd
ffmpeg
2. weget下載stable 包
$sudo wget http://ffmpeg.gusari.org/static/64bit/ffmpeg.static.64bit.2014-07-16.tar.gz
3. 解開下載的tar檔
$sudo tar -xzf ffmpeg.static.64bit.2014-07-16.tar.gz
之後會解出ffmpeg與ffprobe二個資料夾
$ls -al
ffmpeg ffmpeg.static.64bit.2014-07-16.tar.gz ffprobe
4. 執行測試
$./ffmpeg -version
列出這一版的資訊
ffmpeg version N-63893-gc69defd
built on Jul 16 2014 05:38:01 with gcc 4.6 (Debian 4.6.3-1)
configuration: --prefix=/root/ffmpeg-static/64bit --extra-cflags='-I/root/ffmpeg-static/64bit/include -static' --extra-ldflags='-L/root/ffmpeg-static/64bit/lib -static' --extra-libs='-lxml2 -lexpat -lfreetype' --enable-static --disable-shared --disable-ffserver --disable-doc --enable-bzlib --enable-zlib --enable-postproc --enable-runtime-cpudetect --enable-libx264 --enable-gpl --enable-libtheora --enable-libvorbis --enable-libmp3lame --enable-gray --enable-libass --enable-libfreetype --enable-libopenjpeg --enable-libspeex --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-version3 --enable-libvpx
libavutil 52. 89.100 / 52. 89.100
libavcodec 55. 66.101 / 55. 66.101
libavformat 55. 43.100 / 55. 43.100
libavdevice 55. 13.101 / 55. 13.101
libavfilter 4. 8.100 / 4. 8.100
libswscale 2. 6.100 / 2. 6.100
libswresample 0. 19.100 / 0. 19.100
libpostproc 52. 3.100 / 52. 3.100
5. 如果要在每個路徑下都能使用請做一下symbol link
$sudo ln -s /usr/local/bin/ffmpeg/ffmpeg /usr/bin/ffmpeg
TIP: 軟連結請勿打錯路徑,否則在/usr/bin/ffmpeg 會顯示紅色!!
參考資源
官網stable build
http://ffmpeg.gusari.org/static/64bit/
本文參考
http://stackoverflow.com/questions/15057151/installing-ffmpeg-on-amazon-linux-cpp-gcc-libstdc-dependancies