砍敺 IT_man 2017-3-28 13:02 蝺刻摩 : I# r' d& a$ S" @
" F/ W2 |& h! f$ C
FFmpeg臭甈曉撩憭抒閬閮蝺刻圾蝣澆極瘀臭誑憭折蝺函Ⅳ澆ffmpeg舫曉蝣潘汪inux撟喳唬潘銋臭誑典嗅雿璆剔頂蝏銝蝺刻陌瑁嚗WindowsMac OS X蝑
* F7 ]2 y+ a# y* r$ D0 @! c5 D# `) }8 Q3 a
寞銝:8 H7 _+ a3 l$ T5 W5 w9 \9 a" O
; c+ |% o C* P1 @" ]5 o. f[摰鋆]
* L- j+ t( `6 Y: E$ O% |) x3 E* `[/usr/local]#tar -jxvf ffmpeg-2.5.3.tar.bz23 Q7 d% ^; q. {% D
[/usr/local]#cd ffmpeg-2.5.3
9 T3 g* K: K; s' \8 @
7 o. o& t) u" a: E" K; F6 `+ [: Z9 h
摰鋆yasm4 p0 Q$ l. O/ M* `* C( b4 S: K$ c
ffmpeg蝺刻陌銝剔箔擃compile摨佗雿輻其舐楊隞歹鈭舫閬雿輻券撌亙瑯# t- a8 P3 o- u W/ J S& j
[/usr/local/ffmpeg-2.5.3]#yum -y install yasm
2 d, B! z6 F/ N9 z) n璅雿輻冽蝣潭孵摰鋆嚗銝頛yasm皞隞蝣潘嗅雿輻./configuremake隞亙make istall脰摰鋆
8 A4 A" s( o9 I$ \& i5 l[/usr/local/ffmpeg-2.5.3]#./configure --enable-shared --prefix=/usr/local/ffmpeg: J4 x, L& R1 r3 o
嗡葉enable-shared銵函內Y亙澈嚗臭誑靘隞亙蝺函雿輻剁臬瑁蝔摨銋靘鞈湧鈭摨怒憒銝銝enable-shared賊雿輻券亦孵蝺刻陌嚗甇斗銝Y摨恬Yffmpeg蝑臬瑁瑼銋瘥頛憭改雿隞銝閬摨怠停臭誑湔亙瑁# K. E% }' D' {# R
prefix銵函內撌亙瑕鋆桅嚗鋆∟身/usr/local/ffmpeg- x1 N v- p( I0 K" m+ T& s
[/usr/local/ffmpeg-2.5.3]#make . {6 D2 o& R8 ~- D# T5 V% X9 m Y+ \
[/usr/local/ffmpeg-2.5.3]#make install
0 w3 `; X; V* N/ x; E7 p1 X7 u7 i! }3 ]4 R" b
5 P/ c+ v! S+ L" P1 x, A頝臬:摰鋆摰/usr/local/ffmpegY銝桅嚗 - bin嚗臬瑁瑼桅
- lib嚗亙澈桅
- include嚗蝺函典啁剜隞嗥桅5 g+ X: n9 _% n1 I, B/ Q
銝蝞⊥航帷ompile臬臬瑁蝔摨瑁賡閬靘鞈惻ib銝Y摨恬臭誑Yso隞嗆瑁/usr/lib銝嚗銋臭誑湔乩耨寥蝵格隞嗚亦/etc/ld.so.conf隞塚
3 T3 ~: u" `& z$ l- A[/usr/local/ffmpeg-2.5.3]#vi /etc/ld.so.conf7 o6 _6 d$ t' Y6 r4 \$ n* K
include ld.so.conf.d/*.conf: b6 ]% Q9 G! H6 P% m
. a k8 J5 e. i潭臬臭誑/etc/ld.so.conf.d/撱箔啁隞逵fmpeg.conf嚗啣銝銵嚗喟榻fmpeglib桅嚗
5 B- i7 R0 P6 ?, `# ?. W/usr/local/ffmpeg/lib% h; a5 I4 _1 J. d! P3 X
瑁ldconfig嚗湔追d.so.cache嚗雿蹂耨寧When run ldconfig show error:
0 s [: J K# J9 W( uldconfig: /usr/lib64/libgd.so.2 銝臭蝚西交 ==>( r4 Q1 u1 ~3 {0 H
ll /usr/lib64/
# @$ e0 l! E3 H( l3 T-rwxr-xr-x 1 root root 275328 2015-01-11 08:03 /usr/lib64/libgd.so.2
* W) }6 G4 e0 t% c z6 b0 j-rwxr-xr-x 1 root root 275328 2015-01-11 08:03 /usr/lib64/libgd.so.2.0.0
) S0 @, |- B7 Q: i" d# k: VSo:
4 V" |& L2 X/ Xln -s /usr/lib64/libgd.so.2.0.0 /usr/lib64/libgd.so.2 撠梯圾瘙. u0 m: N2 v6 k6 g2 V5 F; k: t
臭誑 vi /etc/ld.so.cache /usr/local/ffmpeg/lib 臬血歇 cache銝
9 J3 B2 z: l! A8 c
3 ?1 R0 G2 @9 e5 b, \9 w" s箔其遙雿唳寡賢湔亦狄fmpeg瑁嚗銝其蝙典./ffmpeg /usr/local/ffmpeg/bin/ffmpeg孵瑁甇文極瘀臭誑臬瑁瑼獢銴鋆賢軔in桅銝嚗灸in桅銝撱箇頠蝯憿隡潔Windows銝瑕嚗憒臬瑁瑼獢鋡怠支嚗頠蝯銋銝賜匱蝥雿輻剁蝖祇蝯臭誑蝜潛雿輻具撱粹蝯賭誘憒銝嚗 2 U1 t+ o) p4 ^/ a0 G. t. p# D
4 B5 [2 \: J! }! K& Dsudo ln -s /usr/local/ffmpeg/bin/ffmpeg /usr/local/bin/ or [/usr/local/bin]# sudo ln -s /usr/local/ffmpeg/bin/ffmpeg .
/ H* Y, g6 N+ {& R0 @+ ksudo ln -s /usr/local/ffmpeg/bin/ffprobe /usr/local/bin/ or [/usr/local/bin]# sudo ln -s /usr/local/ffmpeg/bin/ffprobe . & y5 r6 d( G) O% W0 H
sudo ln -s /usr/local/ffmpeg/bin/ffserver /usr/local/bin/ or [/usr/local/bin]# sudo ln -s /usr/local/ffmpeg/bin/ffserver .
5 J+ `2 o7 O" ^. f
* C6 b) n) F! |. t血嚗憒閬剌fmpeg剜隞塚憟賢include桅銝ffmpeg銴鋆賢/usr/include銝准$ L, [ e8 ~6 Q4 E
曉典臭誑究hell銝剔湔亥撓卯fmpeg瑁嚗蝯憒銝嚗% P/ P6 \9 M; r _0 C I2 n
! k: H1 x+ G I' ]
% P% v2 A$ _' T$ e8 n2 I4 ^[root@CentOS6 bin]# ffmpeg
b) y' L5 z' ]ffmpeg version 2.3.git Copyright (c) 2000-2014 the FFmpeg developers
% i/ z# M3 h- u2 S$ }# ] built on Oct 9 2015 16:11:13 with gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-4)
3 [5 @ j. h8 s0 s8 d configuration: --enable-shared --prefix=/usr/local/ffmpeg4 i" o% X" m: b) S
libavutil 54. 7.100 / 54. 7.1000 D) x2 k1 {5 F$ l, d* I
libavcodec 56. 1.100 / 56. 1.1003 o. |4 d: f4 K. ~3 a0 _
libavformat 56. 4.100 / 56. 4.100
, x& v( p6 T( j6 y2 y: P( I libavdevice 56. 0.100 / 56. 0.100
/ R% ~) p# h; M! H9 ~2 E" O libavfilter 5. 1.100 / 5. 1.100" k8 C, E2 Q# W: I4 ?# L8 R
libswscale 3. 0.100 / 3. 0.100
! K, R; m( k% S libswresample 1. 1.100 / 1. 1.100" J, h. y, \! d) H- x% Z
Hyper fast Audio and Video encoder
; G4 k7 n' Q" d8 `2 B9 kusage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...
4 x: B9 L% {, G2 |) S- M& D' _5 GUse -h to get full help or, even better, run 'man ffmpeg'
8 i( ]' f$ F6 Q& {, Q
! z T3 l* f6 G6 L* ?寞鈭:
2 b2 I3 `$ V) M/ q: G/ q, o0 |, ?: b
* ?, o# P- u) e隞 ffmpeginstaller 摰鋆 ffmpeg 賊憟隞:2 |5 ^" B7 N; o- c( \7 w b# }
9 Q C2 n' a) `7 E0 b
http://ffmpeginstaller.com銝頛唳摰桅嚗靘憒嚗/tmp/
$ Z3 Q5 P& ^) Z e8 L閫憯蝮格敺嚗Y銝 ffmpeginstaller+祈 桅嚗靘憒嚗銝頛閫敺桅+ X v- `/ s0 v4 s6 h
/tmp/ffmpeginstaller.8.0/+ \ n. o r: R8 m# |
脣餌桅敺嚗銝隞支誑瑁
& O+ L4 t# R0 l- a& m
/ W# ~+ ^: X6 ^, \[root]# ./install
9 e! G- ]' F# U# t
3 h/ q1 x" o" u1 Z0 q摰鋆蝔撘撠望憪脰摰鋆嚗閬瘜芸楛銝蝬脣颱頛閬瑼獢
+ o) {5 K% D# r+ T9 c* X L3 M嗅祕摰鋆蝔撘撠望 yum install 單穿摰鋆蝔憭抒 1 撠
( s2 Q: H* I6 B- f$ ^9 g* v銝 ffmpeginstaller 摰鋆頝ffmpeg賊憟隞塚
* W+ K+ I A- I* z
' I3 F& e( @3 x4 Y+ F* a$ A
! a$ N( a: x2 L( B/ u( O
9 e( P" I! \. ~1 q1 c% S: http://oldgrayduck.blogspot.tw/2 ... staller-ffmpeg.html
/ X( y( X# I0 O- ~: E
2 K$ C: s' L5 E, I' a K& [6 \, R3 _4 m" R( q6 m# K9 k- E& N& x
( @6 y% H3 E2 a/ w2 o" l4 F4 n |
|