Build Instructions (Voreen 5.0)

This page gives a rough overview of the Voreen build process using CMake. For more detailed instructions, please refer to the platform-specific build guides.

0. Preparations:

  • Obtain Voreen source distribution
  • Install CMake build system
  • Install Qt 5 library (+ further mandatory libraries on Unix)

1. Initialize CMake Build

  • Set CMake source directory to Voreen base directory (where the CMakeLists.txt is located)
  • Select arbitrary build directory (we support both in-source as well as out-of-source builds)

2. Configure Voreen Build

All Voreen-specific CMake options are prefixed with VRN_. The most important ones are:

  • The VRN_BUILD_* options determine which Voreen libraries and applications are actually built. Usually, you will need the tgt, voreencore, and voreenqt libraries as well as the VoreenVE application.
  • The VRN_MODULE_*  options determine which modules are included in the build. We suggest to start with the default configuration and add further modules later on according to your needs.

Further options:

  • VRN_CUSTOM_MODULEDIR: directory where your custom Voreen modules are located (custommodules/ by default)
  • VRN_PRECOMPILED_HEADER: use precompiled headers (reduces build time significantly), Windows only
  • VRN_ADD_INSTALL_TARGET: Generates an install target/project that copies binaries, external libraries, shaders, and further resources to the target directory specified by CMAKE_INSTALL_PREFIX.

Windows-specific options:

  • VRN_COPY_EXTERNAL_DLLS: Copies the DLLs of external libraries to the bin/debug and bin/release directories, respectively.
  • VRN_INCREMENTAL_LINKING: Enables incremental linking in Visual Studio debug builds, which speeds up rebuilds after minor changes, but might cause linker errors in rare situations.
  • VRN_GROUP_SOURCE_FILES: Groups source in Visual Studio projects by sub directory.
  • VRN_DISABLE_ZERO_CHECK: Disable ZERO_CHECK target in Visual Studio in order to prevent unnecessary PCH re-compilations.

3. Generate Project and Build It

  • The binaries are put to the bin/ subdirectory

Note: Using Visual Studio 2012 and 2013 you might encounter the following error: "Linker fatal error: LNK1102: out of memory". This might occur whenever many modules adding huge libraries like ITK, GDCM are enabled. Disabling VRN_INCREMENTAL_LINKING might fix the issue. If it does not, however, you will need to disable some modules.