您的位置:首页 > 其它

vlc在Ubuntu下的自动安装和手动安装

2010-09-06 21:39 447 查看
“乾,元亨利贞”

--《易经》

VLC Media Player是和Mplayer齐名的优秀的开源播放器。

我想用它休闲娱乐,也想做二次开发,当然不想后者的不成熟打扰前者,故做两种安装就很必要啦。

官网上有讲如何安装和编译,但有些凌乱,现将我的实践记录并整理如下。

I. 用于播放的安装

Ubuntu下的安装很容易,

在命令行下:

$ sudo apt-get install vlc

如果想要插件,则在后面加上相应的插件选项即可:

vlc-plugin-alsa- ALSA audio output plugin for VLC (install it if sound doesn't work)
vlc-plugin-arts- aRts audio output plugin for VLC (install it if sound still doesn't work and you're using KDE)
vlc-plugin-esd - Esound audio output plugin for VLC (install it if sound still doesn't work and you're using Gnome)
vlc-plugin-ggi - GGI video output plugin for VLC
vlc-plugin-glide - Glide video output plugin for VLC
vlc-plugin-pulse - PulseAudio audio output plugin for VLC
vlc-plugin-sdl - SDL video and audio output plugin for VLC
vlc-plugin-svgalib - SVGAlib video output plugin for VLC
mozilla-plugin-vlc - the VLC plugin for Mozilla based browsers

等它们完成后就搞定了。在“应用程序”的菜单中就可以找到新安装的VLC播放器。

[/code]
II. 用于开发的安装

先到官网(http://www.wiki.videolan.org/GetTheSource)上下载最新的release包,我下的是“vlc-1.1.4.tar.bz2”.

解压:

$tar -jxvf vlc-1.1.4.tar.bz2

后会生成目录:vlc-1.1.4

$ cd vlc-1.1.4;

$ ./bootstrap; /*它主要进行各个模块的配置 */

$ cd extras/contrib;

$ ./bootstrap;

$ make;/* 下载并build vlc官网提供的库,这个时间会有点长,我的机器发了20分钟 */

接着就要另外安装第三库如x264,ffmpeg,live555

$ git done git://git.videolan.org/x264.git x264-trunk

$ cd x264-trunk;

$./configure --prefix=/想要另外安装的目录/

$ make;

$ cd ..

$ svn checkout svn://svn.ffmpeg.org/ffmpeg/trunk ffmpeg

$ cd ffmpeg

$ ./configure --prefix=/想要另外安装的目录/ --enable-gpl --enable-pthreads --enable-libmp3lame --enable-libfaac --enable-nonfree

$ make

$ cd ..

$ wget http://www.live555.com/liveMedia/public/live555-latest.tar.gz
$ tar xvzf live555-latest.tar.gz

$ cd live

$ sh genMakefiles linux;

$ make

最后进行整个vlc的配置和build:

$ cd ..

$ cd ..

配置之一:

$ mkdir build && cd build && ../configure --prefix=/想要安装的目录 /

--enable-snapshot --enable-debug /

--enable-dbus-control --enable-musicbrainz /

--enable-shared-libvlc --enable-mozilla /

--enable-lirc /

--enable-live555 --with-live555-tree=../extras/live /

--enable-x264 --with-x264-tree=../extras/x264-trunk /

--enable-shout --enable-taglib /

--enable-v4l --enable-cddax /

--enable-dvb --enable-vcdx /

--enable-realrtsp --enable-xvmc /

--enable-svg --enable-dvdread /

--enable-dc1394 --enable-dv /

--enable-theora --enable-faad /

--enable-twolame --enable-real /

--enable-flac --enable-tremor /

--with-ffmpeg-mp3lame --with-ffmpeg-faac /

--enable-quicktime --enable-dirac /

--enable-skins2 --enable-qt4 /

--enable-ncurses /

--enable-aa --enable-caca /

--enable-esd --enable-portaudio /

--enable-jack --enable-xosd /

--enable-galaktos --enable-goom /

--enable-ggi /

--disable-cddax --disable-vcdx

配置之二:

$ ./configure --enable-x11 --enable-xvideo --disable-gtk --enable-sdl --enable-avcodec --enable-avformat --enable-swscale --enable-mad --enable-libdvbpsi --enable-a52 --enable-libmpeg2 --enable-dvdnav --enable-faad --enable-vorbis --enable-ogg --enable-theora --enable-faac --enable-mkv --enable-freetype --enable-fribidi --enable-speex --enable-flac --enable-live555 --with-live555-tree=/usr/lib/live --enable-caca --enable-skins --enable-skins2 --enable-alsa --disable-kde --enable-qt4 --enable-ncurses --enable-release

注意,如果有失败的,可以将相应的选项关闭;

最后,

$ make

$ make install 


                                            
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: