From 3974cb7e4821b4e131cd677fd609433a05c453b3 Mon Sep 17 00:00:00 2001 From: Wildemann Stefan Date: Tue, 18 Jun 2019 10:46:36 +0200 Subject: Disable maptool if protobuf-c not found --- CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 3e6d4c683..a03cdc835 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -687,6 +687,13 @@ if(CMAKE_SIZEOF_VOID_P LESS 8) set_with_reason(BUILD_MAPTOOL "maptool works only on 64 bit architectures" FALSE) endif() +if(BUILD_MAPTOOL) + find_package(Protobuf-c REQUIRED) + if(NOT PROTOBUF_C_FOUND) + set_with_reason(BUILD_MAPTOOL "PROTOBUF-C not found" FALSE) + endif() +endif() + set(LOCALEDIR "${LOCALE_DIR}") find_program(BZCAT NAMES bzcat) -- cgit v1.2.1