/vc-deps

CMake project for building Volume Cartographer dependencies from source

Primary LanguageCMakeGNU Affero General Public License v3.0AGPL-3.0

Volume Cartographer Dependency Builder

CMake project to build Volume Cartographer dependencies.

Requirements

  • C++17 compiler
  • CMake 3.24+

Get The Source

git clone https://github.com/educelab/vc-deps.git
cd vc-deps/

Installation

mkdir -p build/
cd build/
cmake ..
make -j

By default, dependencies will be installed into the vc-deps/deps/ subdirectory. To install to a different location, set the CMAKE_INSTALL_PREFIX CMake flag to your desired installation prefix.

Enable/Disable Libraries

Building a particular dependency can be controlled with the VCDEPS_BUILD_* flags. For example, configuring CMake with the following flag will disable the vc-deps build of ITK:

cmake -DVCDEPS_BUILD_ITK=OFF ..

Note that certain libraries provided by this package are prerequisites to building other libraries in vc-deps (e.g. libtiff is needed to build ITK from source). If one of these prerequisite libraries is disabled, vc-deps will check the system path for an already installed replacement. If a compatible library is not found, the build will fail.

To see a full list of available build options, use ccmake or run:

cmake -L ..

Build Types and Static or Shared Libraries

Optionally, you can create Release/Debug builds and static/shared libraries by providing the corresponding CMake arguments:

cmake -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=ON ..

Position Independent Code

To build libraries with position independent code (PIC), set the CMAKE_POSITION_INDEPENDENT_CODE flag:

cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON ..

PIC is ON by default when building shared libraries, so this flag will only affect static builds. This flag must be enabled to successfully link Volume Cartographer's Python bindings against statically built dependencies.