オーディオ・ビデオエンコーダFFmpegについて。

svn trunkのソースからのビルド・インストール

本文は2009年03月23日(リビジョン18169)時点のバージョンに基づく。

ビルド時にYasmアセンブラを使用する場合はあらかじめYasmをインストールしておく。

ソースのチェックアウトとconfigure。

svn co svn://svn.mplayerhq.hu/ffmpeg/trunk ./ffmpeg
cd ffmpeg/
./configure

configureのオプション等は後述。 問題が無ければ、make、make installする。

make
sudo make install

configureの例

./configure \
--prefix=/usr/local --enable-static --enable-shared \
--arch=x86_64 --cpu=athlon64 --extra-ldflags='-L/usr/local/lib -Wl,-rpath,/usr/local/lib:/usr/lib:/lib,-ldl' \
--enable-pthreads --disable-debug --disable-ffserver --enable-ffplay --enable-x11grab \
--enable-gpl --enable-nonfree --enable-memalign-hack --enable-postproc --enable-avfilter --enable-avfilter-lavf \
--enable-libx264 --enable-libfaac --enable-libfaad --enable-libfaadbin --enable-libtheora --enable-libvorbis \
--disable-libmp3lame --disable-libxvid --disable-libgsm --disable-libdc1394 \
--disable-indevs
  • オプションの内容
    • ターゲットアーキテクチャはx86_64 (--arch=x86_64)
    • ターゲットCPUはathlon64 (--cpu=athlon64)
    • /usr/local/libのライブラリを優先して参照 (--extra-ldflags=)
    • デバッグ用のコードを無効にする (--disable-debug)
    • FFServerをビルドしない (--disable-ffserver)
    • FFPlayをビルドする (--enable-ffplay)
    • GPLコードをビルドする (--enable-gpl)
    • 再配布不可となるコードをビルドする (--enable-nonfree)
    • libx264、libfaac、libfaad、libtheora、libvorbisを使用する (--enable-lib*)
    • libmp3lame、libxvid、libgsm、libdc1394を使用しない (--disable-lib*)
    • V4L等のindevsを使用しない (--disable-indevs)

上記configureの実行例。

install prefix            /usr/local
source path               /home/santamarta/build/ffmpeg
C compiler                gcc
.align is power-of-two    no
ARCH                      x86 (athlon64)
big-endian                no
yasm                      yes
MMX enabled               yes
MMX2 enabled              yes
3DNow! enabled            yes
3DNow! extended enabled   yes
SSE enabled               yes
SSSE3 enabled             yes
CMOV enabled              yes
CMOV is fast              yes
EBX available             yes
EBP available             yes
10 operands supported     yes
gprof enabled             no
debug symbols             no
strip symbols             yes
optimizations             yes
static                    yes
shared                    yes
postprocessing support    yes
new filter support        yes
filters using lavformat   yes
network support           yes
IPv6 support              yes
threading support         pthreads
SDL support               no
Sun medialib support      no
AVISynth enabled          no
libamr-nb support         no
libamr-wb support         no
libdc1394 support         no
libdirac enabled          no
libfaac enabled           yes
libfaad enabled           yes
libfaad dlopened          yes
libgsm enabled            no
libmp3lame enabled        no
libnut enabled            no
libopenjpeg enabled       no
libschroedinger enabled   no
libspeex enabled          no
libtheora enabled         yes
libvorbis enabled         yes
libx264 enabled           yes
libxvid enabled           no
zlib enabled              yes
bzlib enabled             yes

Enabled decoders:
aac			ffvhuff			pcm_s32be
aasc			flac			pcm_s32le
ac3			flashsv			pcm_s8
adpcm_4xm		flic			pcm_u16be
adpcm_adx		flv			pcm_u16le
adpcm_ct		fourxm			pcm_u24be
adpcm_ea		fraps			pcm_u24le
adpcm_ea_maxis_xa	gif			pcm_u32be
adpcm_ea_r1		h261			pcm_u32le
adpcm_ea_r2		h263			pcm_u8
adpcm_ea_r3		h263i			pcm_zork
adpcm_ea_xas		h264			pcx
adpcm_g726		huffyuv			pgm
adpcm_ima_amv		idcin			pgmyuv
adpcm_ima_dk3		imc			png
adpcm_ima_dk4		indeo2			ppm
adpcm_ima_ea_eacs	indeo3			ptx
adpcm_ima_ea_sead	interplay_dpcm		qcelp
adpcm_ima_iss		interplay_video		qdm2
adpcm_ima_qt		jpegls			qdraw
adpcm_ima_smjpeg	kmvc			qpeg
adpcm_ima_wav		libfaad			qtrle
adpcm_ima_ws		loco			ra_144
adpcm_ms		mace3			ra_288
adpcm_sbpro_2		mace6			rawvideo
adpcm_sbpro_3		mdec			rl2
adpcm_sbpro_4		mimic			roq
adpcm_swf		mjpeg			roq_dpcm
adpcm_thp		mjpegb			rpza
adpcm_xa		mlp			rv10
adpcm_yamaha		mmvideo			rv20
alac			motionpixels		rv30
amv			mp1			rv40
ape			mp2			sgi
asv1			mp3			shorten
asv2			mp3adu			smackaud
atrac3			mp3on4			smacker
avs			mpc7			smc
bethsoftvid		mpc8			snow
bfi			mpeg1video		sol_dpcm
bmp			mpeg2video		sonic
c93			mpeg4			sp5x
cavs			mpegvideo		sunrast
cinepak			msmpeg4v1		svq1
cljr			msmpeg4v2		svq3
cook			msmpeg4v3		targa
cscd			msrle			theora
cyuv			msvideo1		thp
dca			mszh			tiertexseqvideo
dnxhd			nellymoser		tiff
dsicinaudio		nuv			truehd
dsicinvideo		pam			truemotion1
dvbsub			pbm			truemotion2
dvdsub			pcm_alaw		truespeech
dvvideo			pcm_dvd			tscc
dxa			pcm_f32be		tta
eac3			pcm_f32le		txd
eacmv			pcm_f64be		ulti
eatgq			pcm_f64le		vb
eatgv			pcm_mulaw		vc1
eatqi			pcm_s16be		vcr1
eightbps		pcm_s16le		vmdaudio
eightsvx_exp		pcm_s16le_planar	vmdvideo
eightsvx_fib		pcm_s24be		vmnc
escape124		pcm_s24daud		vorbis
ffv1			pcm_s24le		vp3
vp5			wmav2			xan_dpcm
vp6			wmv1			xan_wc3
vp6a			wmv2			xl
vp6f			wmv3			xsub
vqa			wnv1			zlib
wavpack			ws_snd1			zmbv
wmav1

Enabled encoders:
ac3			libx264			pcm_u24le
adpcm_adx		ljpeg			pcm_u32be
adpcm_g726		mjpeg			pcm_u32le
adpcm_ima_qt		mp2			pcm_u8
adpcm_ima_wav		mpeg1video		pcm_zork
adpcm_ms		mpeg2video		pcx
adpcm_swf		mpeg4			pgm
adpcm_yamaha		msmpeg4v1		pgmyuv
alac			msmpeg4v2		png
asv1			msmpeg4v3		ppm
asv2			nellymoser		qtrle
bmp			pam			rawvideo
dnxhd			pbm			roq
dvbsub			pcm_alaw		roq_dpcm
dvdsub			pcm_f32be		rv10
dvvideo			pcm_f32le		rv20
ffv1			pcm_f64be		sgi
ffvhuff			pcm_f64le		snow
flac			pcm_mulaw		sonic
flashsv			pcm_s16be		sonic_ls
flv			pcm_s16le		svq1
gif			pcm_s24be		targa
h261			pcm_s24daud		tiff
h263			pcm_s24le		vorbis
h263p			pcm_s32be		wmav1
huffyuv			pcm_s32le		wmav2
jpegls			pcm_s8			wmv1
libfaac			pcm_u16be		wmv2
libtheora		pcm_u16le		zlib
libvorbis		pcm_u24be		zmbv

Enabled parsers:
aac			dvdsub			mpeg4video
ac3			h261			mpegaudio
cavsvideo		h263			mpegvideo
dca			h264			pnm
dirac			mjpeg			vc1
dnxhd			mlp			vp3
dvbsub

Enabled demuxers:
aac			iss			pcm_u16le
ac3			lmlm4			pcm_u24be
aiff			m4v			pcm_u24le
amr			matroska		pcm_u32be
apc			mjpeg			pcm_u32le
ape			mlp			pcm_u8
asf			mm			pva
ass			mmf			r3d
au			mov			rawvideo
avi			mp3			redir
avs			mpc			rl2
bethsoftvid		mpc8			rm
bfi			mpegps			roq
c93			mpegts			rpl
cavsvideo		mpegtsraw		rtsp
daud			mpegvideo		sdp
dirac			msnwc_tcp		segafilm
dnxhd			mtv			shorten
dsicin			mvi			siff
dts			mxf			smacker
dv			nc			sol
dxa			nsv			str
ea			nut			swf
ea_cdata		nuv			thp
eac3			ogg			tiertexseq
ffm			oma			truehd
flac			pcm_alaw		tta
flic			pcm_f32be		txd
flv			pcm_f32le		vc1
fourxm			pcm_f64be		vc1t
gsm			pcm_f64le		vmd
gxf			pcm_mulaw		voc
h261			pcm_s16be		vqf
h263			pcm_s16le		wav
h264			pcm_s24be		wc3
idcin			pcm_s24le		wsaud
iff			pcm_s32be		wsvqa
image2			pcm_s32le		wv
image2pipe		pcm_s8			xa
ingenient		pcm_u16be		yuv4mpegpipe
ipmovie

Enabled muxers:
ac3			m4v			pcm_mulaw
adts			matroska		pcm_s16be
aiff			matroska_audio		pcm_s16le
amr			mjpeg			pcm_s24be
asf			mmf			pcm_s24le
asf_stream		mov			pcm_s32be
ass			mp2			pcm_s32le
au			mp3			pcm_s8
avi			mp4			pcm_u16be
avm2			mpeg1system		pcm_u16le
crc			mpeg1vcd		pcm_u24be
daud			mpeg1video		pcm_u24le
dirac			mpeg2dvd		pcm_u32be
dnxhd			mpeg2svcd		pcm_u32le
dts			mpeg2video		pcm_u8
dv			mpeg2vob		psp
eac3			mpegts			rawvideo
ffm			mpjpeg			rm
flac			mxf			roq
flv			mxf_d10			rtp
framecrc		null			swf
gif			nut			tg2
gxf			ogg			tgp
h261			pcm_alaw		truehd
h263			pcm_f32be		vc1t
h264			pcm_f32le		voc
image2			pcm_f64be		wav
image2pipe		pcm_f64le		yuv4mpegpipe
ipod

Enabled protocols:
file			pipe			tcp
gopher			rtp			udp
http

Enabled filters:
crop

Enabled bsfs:
dump_extradata		mov2textsub		noise
h264_mp4toannexb	mp3_header_compress	remove_extradata
imx_dump_header		mp3_header_decompress	text2movsub
mjpega_dump_header

Enabled indevs:

Enabled outdevs:
oss

License: unredistributable
Creating config.mak and config.h...
config.h is unchanged