Table of Contents

Compiling Avidemux 2.5.x

Prerequisites

To compile Avidemux, you will need all the source building essentials and dependencies and the program source code itself before you can begin.

Compiler tool essentials

To actually do any compiling, you will need the basic tools. Many Linux distributions, such as Ubuntu (and all variations, including Kubuntu, Mythbuntu, etc.) and Debian have a package called build-essential which simplifies the process of getting all your need to being compiling programs.

To install this package, do the following on the command line:

apt-get install build-essential

Automatically getting dependencies (Linux only)

If you have the apt-package system in your Linux distribution, you may be able to use its features to help automatically grab many of the dependencies needed for compilation. Linux Distributions which use the apt-system are Ubuntu (and all variations, including Kubuntu, Mythbuntu, etc.), Debian, and others. Red(nbsp)Hat and friends use apt-rpm, which is basically the same.

If your distribution already the Avidemux package in their apt repositories, this command may work for you.

sudo apt-get build-dep avidemux

This will install numerous packages needed for Avidemux.

Manually getting dependencies (Linux only)

Please note this list is meant to be used on Ubuntu, though it may work for Debian and other similar systems. This list is not exhaustive. This command will install many necessary and extra dependency packages for Avidemux to be compiled. Run this in command line:

sudo apt-get install \
 build-essential \
 cmake \
 gettext \
 liba52-0.7.4 \
 liba52-0.7.4-dev \
 libasound2-dev \
 libarts1-dev \
 libfaac-dev \
 libfaad-dev \
 libgtk2.0-dev \
 libglib2.0-dev \
 libmad0-dev \
 libqt4-dev \
 libvorbis-dev \
 libx264-dev \
 libxv-dev \
 libxml2-dev \
 libxvidcore-dev \
 pkg-config \
 subversion

Unless you use KDE 3 with aRts, you don't need libarts (libarts1-dev). It's obsolete (and therefore not available in the default repositories anymore).

Getting the source

To get the source code for Avidemux, you can either download the source archive (a *.tar.gz file) from one of the mirrors at http://www.avidemux.org. You will need to extract the files from the *.tar.gz file to compile them.

Optionally you can download the source code from the stable SVN source branch.

svn co svn://svn.berlios.de/avidemux/branches/avidemux_2.5_branch_gruntster/

Note, you will need to have the program Subversion installed to do this.

Starting with version 2.5.x Avidemux include a script designed to help automatically compile the source code. (This was done because Avidemux is moving towards a more modularized system, resulting in a more complex manual compile process. This script is designed to be simple and painless for everyone.)

On the command line, change directories into the folder location where you have extracted/downloaded the Avidemux source code. To use the auto-compile script, do the following in the terminal.

sudo ./bootStrap.sh

The rest of the compilation should be automatic and fairly painless.

Manual compilation

Avidemux is moving towards a more modularized system, where the plugins are separate from the core of the program. Thus, to compile and have Avidemux with all its full features, now the compilation must take place in two stages.

1st is the main application Avidemux, and 2nd is the Avidemux plugins.

Main application

As for avidemux 2.4.x, create your build directory then

cmake  *path to source dir*
make
make install

Plugins

The plugins needs some informations coming from the main application build. It needs :

And that's it. In no way it needs a full build tree of the main application.

Then create your build directory and

cmake -DAVIDEMUX_LIB_DIR=/usr/lib -DAVIDEMUX_SOURCE_DIR=/home/foobar/avidemux \
-DAVIDEMUX_CORECONFIG_DIR=/home/foobar/avidemux/build/config PATH_TO_PLUGIN_DIR
make

Please note the following:

Example Ubuntu manual compilation

If you are using a version > 2.5.0 or using SVN, you should try first running the bootStrap.sh script that will compile and install Avidemux.

Here is an example for how to compile Avidemux 2.5 in Ubuntu. We assume you have the extra libraries and codec packages installed already. We also assume you have downloaded the Avidemux 2.5 source (from SVN or tarball). Let's say downloaded the source files to /home/user_name/avidemux_2.5_grunster.

First stage is to build Avidemux itself.

cd /home/user_name/avidemux_2.5_grunster # Or wherever you downloaded the source file
mkdir build
cd build
cmake ..
make
sudo make install
sudo ldconfig # This step is necessary for Ubuntu

Second stage is to build the plugins for Avidemux, continuing from the first stage.

cd /home/user_name/avidemux_2.5_grunster/plugins/
mkdir build
cd build
cmake -DAVIDEMUX_LIB_DIR=/usr/lib -DAVIDEMUX_SOURCE_DIR=/home/user_name/avidemux_2.5_branch_gruntster \
-DAVIDEMUX_CORECONFIG_DIR=/home/user_name/avidemux_2.5_branch_gruntster/build/config \
-DAVIDEMUX_INSTALL_PREFIX=/usr/local .. # Avidemux will be installed to /usr/local
make
sudo make install
sudo ldconfig # This step is necessary for Ubuntu