Hugin Compiling Ubuntu
These instructions are work in progress. Initially tested on a blank installation of Kubuntu 6.06 (Edgy Eft) on a AMD64 computer, they have also been tested on Ubuntu 7.04 on a AMD64 computer and Ubuntu 7.10 on an AMD Athlon XP computer. Apart from the odd change in package name, nothing should be substantially different (and if does not work, please leave a comment here and on the hugin-ptx mailing list. Don't worry if the same package appears twice in an apt-get install line - apt-get will update existing packages if there is a newer version, and ignore duplicates if the latest version is already installed. On the other hand, if apt-get says that it can't find a package, it might be the odd change in package name. You can find a replacement package by using apt-cache search with a substring of the package required, e.g.
apt-cache search wxW
The goal is to build hugin and the whole set of helper applications required.
Since we are going to build hugin, libpano13 and enblend we need to download and install all the development packages. This is very easy with apt-get. In a terminal window (K menu/System/Konsole)
sudo apt-get install build-essential autoconf automake1.9 libtool flex bison gdb
In a amd64 environment you will need the following packages
sudo apt-get install libc6-dev-amd64 lib64gcc1
In a i386 system the equivalent is probably (COULD SOMEBODY CHECK THIS ONE?)
sudo apt-get install libc6-dev libgcc1
To get the bleeding edge we'll need access to the SVN and CVS repositories, and for this we need the correct tools:
sudo apt-get install subversion cvs
Get the dependencies. If you are working with large images (300 megapixels and up), you should have a libtiff-devel compiled with large file support and libstdc++6.
sudo apt-get install pkg-config libtiff4-dev libboost-graph-dev libboost-thread-dev \ liblcms1-dev libglew-dev libplot-dev libglut3-dev libopenexr-dev libopenexr2c2a
Once all dependencies are in place, we get the code from CVS (simply press ENTER when prompted for a password on the login command) and build it.
cvs -d:pserver:firstname.lastname@example.org:/cvsroot/enblend login cvs -z3 -d:pserver:email@example.com:/cvsroot/enblend co -P enblend cd enblend make -f Makefile.cvs ./configure make
The make step can be very long and memory consuming. Make sure you have enough swap space, and go get a healthy snack while the computer is compiling.
If you encounter problems at any of these stages, please report back to the hugin-ptx mailing list. Report what command in the sequence you were executing, what machine/operating system, the revision checked out from CVS, and all other relevant information.
libpano13 is the new version of the PanoTools libraries. This is a necessary component for hugin, and we need to build it first.
To build libpano13 we need some libraries and particularly their
sudo apt-get install lib64z1 lib64z1-dev libpng12-dev libjpeg62-dev libtiff4-dev
We then need to download the source code from SVN:
svn co https://panotools.svn.sourceforge.net/svnroot/panotools/trunk/libpano libpano13 cd libpano13 ./bootstrap
If any libraries are missing, the script will complain (or at least, let you know that some library hasn't been found). In that case you probably need to install the library. To find in what package is that library, a general rule is to run the command
apt-cache search missingfile, find the relevant library and install both the library and the related
./configure script and repeat this process until you have met all the dependencies.
Then we are ready to launch the make process with
If the library successfully compiles, you have to install it with
sudo make install sudo ldconfig
The last part is for the OS to be aware of the new library (that has been installed in
We can now go back up one folder level and get ready for hugin.
Some additional libraries are needed. We need first to activate the
universe repository (in adept package manager, or by editing the /etc/apt/sources.lst file for example).
sudo apt-get install cmake libopenexr-dev libboost-dev boost-build libboost-thread-dev libboost-graph-dev
We download the source from SVN, as before
svn co https://hugin.svn.sourceforge.net/svnroot/hugin/hugin/trunk/ hugin cd hugin
hugin has to be built using cmake (which we installed before).
cmake -DCMAKE_INSTALL_PREFIX=/usr/local .
Note: If we want to compile the additional tools, such as align_image_stack, we need to de-comment the "add_subdirectory(tools)" line in the CMakeLists.txt file located in hugin/src/hugin1 before cmaking. Don't forget to copy (or link) the align_image_stack binary to /usr/local/bin if you want to use it with external applications, such as qtpsfgui.
Finally, launch the compilation and installation with
make sudo make install