Skip to content

OTB Superbuild don't support "Ninja" as generator and build system

Description

Some external projects in OTB Superbuild are not compatible with ninja build system. It is not possible for now to specify Ninja as the cmake generator and use it to buld external projects (including OTB)

For instance:

  • OPENSSL external project include a custom BUILD_COMMAND which points to the variable ${MAKE} on Unix system which leads to an internal error of ninja:

ninja: error: build.ninja:458: bad $-escape (literal $ must be written as $$)

  • Issue with ZLIB installation sequence with the following error:
Command failed: 1

   'env' 'CC=/usr/bin/cc' 'CXX=/usr/bin/c++' '/usr/bin/cmake' '-GNinja' '--build' '.' '--target' 'install'

Steps to reproduce

cmake -DCMAKE_GENERATOR=Ninja ${otb_source_directory}/SuperBuild/ ninja

Configuration information

OS, OTB version or tag, information related to build (binaries, superbuild, system libs ...)

Edited by Manuel Grizonnet