How to Compile

HARP is compiled as any typical CMake project: create a build dir, change into it and call cmake. Before you start, make sure you have all prerequisites installed. Depending on your system, different command might be required for this. If you are working under Ubuntu, Suse, or Cent OS, please see the following section. If you successfully compiled HARP on a Windows machine or another Linux distribution, please let us know about it!

Please report any bugs to dominic[DOT]h[DOT]springer[AT]gmail.com

Thank you!

 

Prerequisites under Ubuntu 14.04, Suse 12.04 and CentOS 6 (all 64-Bit)

HARP is designed as an easy-to-use development toolkit for both new and experienced HEVC developers. We strongly recommend that you first go with the proposed C++ / Python / Eclipse 4.3+ workflow and only then reduce HARP to your needs (like leaving out packets, using older Eclipse versions, C++ workflow only etc.).

Eclipse 4.3+

Do not use the Eclipse that comes with apt-get or zypper, it is fairly outdated and will not work properly with HARP. Instead, go to www.eclipse.org/downloads/, grab the "Eclipse IDE for C/C++ Developers" 4.3 64-Bit and extract it to a directory (recommended: ~/bin/eclipse). Eclipse 4.4 is fairly new and seems to have some Java issues on at least Suse 12.04, so we recommend Eclipse 4.3 (for now). Remember the path where you extracted Eclipse. CMake needs this information to create Eclipse project files for you!

Dependencies

All package dependencies are quite simple to setup. Just get a hot tea while the package manager sets up everything for you:

Ubuntu: sudo apt-get install build-essential libopencv-dev python-opencv qt4-default cmake valgrind libpython2.7-dev python-numpy python-scipy python-matplotlib python-pyinotify

Suse: sudo zypper install make gcc cmake python-numpy-devel opencv-devel python-opencv libqt4-devel python-qt4 python-imaging python-scipy

CentOS: Somehow more difficult. CMake and OpenCV are too outdated, at least on CentOS 6.5. However, OpenCV and CMake compilation is straight forward and widely described on the net. OpenCV needs to build the Python bindings, so make sure they are activated after configuration. If you choose to install OpenCV to a custom folder in your home directory, make sure you adjust CMakeLists.txt to this path (uncomment and edit the two lines above the find_package(OpenCV REQUIRED) statement). Also make sure your shiny new CMake is found in the PATH (test it with "which cmake").

 

Compiling HARP, including HM

Download HARP, extract it to any directory and open a terminal (we will assume HARP under ~/Desktop/HARP in the following). If you installed Eclipse under ~/bin/eclipse, you might start right away, otherwise open the script a_build_HARP.sh in an editor and change ECLIPSE_BIN to the correct path to the Eclipse binary.

Then, call:
./a_build_HARP.sh

This will create a directory "HARP Build" on the same level than "HARP", configure HARP with CMake, compile HARP and create Eclipse project files. This script is just a few lines, so feel free to do it manually (open a_build_HARP.sh to see what goes on). If you do it manually: Do NOT choose a build directory INSIDE of the HARP directory, since this will break the Eclipse project files. For an explanation of this limitation, see "Advanced Editing Features" under http://www.cmake.org/Wiki/Eclipse_CDT4_Generator.

Congratulations, you are ready to go! Now see the first HARP tutorial to get some impression of how to use HARP on the command line.

 

Recommendations

We recommend to always have an eye on the cmake output, this will save you a lot of trouble. Especially, make sure Eclipse is found in its correct version 4.3. If everything goes right, it should read something like this:

-- The C compiler identification is GNU 4.8.1
-- The CXX compiler identification is GNU 4.8.1
-- Found Eclipse version 4.3 ()
[...]
================== DEBUG BUILD ==================

-- _______________PYTHON_______________
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found version "2.7.5+")
-- PYTHON_LIBRARIES=/usr/lib/x86_64-linux-gnu/libpython2.7.so
-- PYTHON_INCLUDE_PATH=/usr/include/python2.7
--
-- _______________OPENCV_______________
-- OpenCV_FOUND=1
-- OpenCV_LIB_DIR=/usr/lib;/usr/share/OpenCV/3rdparty/lib
-- OpenCV_INCLUDE_DIRS=/usr/include/opencv;/usr/include
-- OpenCV_LIBS=debug;/usr/lib/libopencv_calib3d.so;debug;[...]
--
-- _______________QT_______________
[...]
-- Found Qt4: /usr/bin/qmake (found version "4.8.4")
-- QT_QTCORE_INCLUDE_DIR=/usr/include/qt4/QtCore
-- QT_QTGUI_INCLUDE_DIR=/usr/include/qt4/QtGui
-- QT_QTCORE_LIBRARY=/usr/lib/x86_64-linux-gnu/libQtCore.so
-- QT_QTGUI_LIBRARY=/usr/lib/x86_64-linux-gnu/libQtGui.so