FFMpeg on Ubuntu 8.10

The goal of this project was to build a video converter for a website kind of like YouTube. Look for more posts on this and extra modules like php-cli scripts and much more.

Let's get going with a FFMpeg installation. I stated with a clean Ubuntu 8.10 Server machine with nothing but ssh server installed.

Add the EXTRA mediabuntu to the list of sources. (on one line)
wget http://www.medibuntu.org/sources.list.d/$(lsb_release -cs).list --output-document=/etc/apt/sources.list.d/medibuntu.list
Generate the key
apt-get update && sudo apt-get install medibuntu-keyring && sudo apt-get update
Then install the codecs from mediabuntu
apt-get install w32codecs
If you have a 64-bit system then use this
apt-get install w64codecs
Install updates and upgrades
apt-get update
apt-get upgrade
Install optional plugins. (should be one line)
apt-get install libsdl1.2-dev zlib1g-dev libfaad-dev libfaac-dev  libmp3lame-dev libtheora-dev libvorbis-dev libxvidcore4-dev  libschroedinger-dev libspeex-dev libgsm1-dev
Now I recommend creating a folder to put all of the compiled software in so we can make build updates in the future.
cd /home/user/
mkdir build
cd build
You might need to install the compilers for your system here is the command for this
apt-get install build-essential
If you don't have "git" installed on your system run this
apt-get install git-core
Installing x264 from source
git clone git://git.videolan.org/x264.git
cd x264
NOTE/UPDATE - I recently had to add another piece of software to my machine to get this to work:
apt-get install yasm
Also needed to install the checkinstall application
apt-get install checkinstall
./configure --enable-shared
sudo checkinstall --fstrans=no --install=yes --pkgname=x264 --pkgversion "1:0.svn`date +%Y%m%d`-0.0ubuntu1"
sudo ldconfig
If you need to install subversion then run this command
apt-get install subversion
Great now you have a x264 encoder plugin. Now we need to build ffmpeg from scratch as well. Make sure and go back into the build folder before beginning this new set.
cd /home/user/build
svn checkout svn://svn.ffmpeg.org/ffmpeg/trunk ffmpeg
cd ffmpeg
./configure --enable-gpl --enable-postproc --enable-pthreads --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libtheora --enable-libx264 --enable-libxvid --enable-libgsm --enable-nonfree
sudo checkinstall --fstrans=no --install=yes --pkgname=ffmpeg --pkgversion "3:0.svn`date +%Y%m%d`-12ubuntu3"
Now the ffmpeg should be read to go. You can test the installation by simply typing ffmpeg at the command line. If you need to recompile the source code you simply have to run from the folders again in the future. Good luck and look for more information


Popular posts from this blog

Console over SSH (ONTAP)

Brocade Zone Setup

OpenSolaris ZFS Setup