From ee6971e9aa9f2c09651e467bc4809d8513e6e0d5 Mon Sep 17 00:00:00 2001 From: Philipp Storz Date: Mon, 17 Dec 2018 15:41:15 +0100 Subject: [PATCH] cmake: require OpenSSL With the new TLS-PSK features in bareos 18 we require OpenSSL for building Cmake now emits a fatal error when OpenSSL is not found. --- core/CMakeLists.txt | 6 ++++-- core/cmake/BareosFindAllLibraries.cmake | 3 +-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index 83e146c052e..60a761c3ab6 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -1,6 +1,6 @@ # BAREOS�� - Backup Archiving REcovery Open Sourced # -# Copyright (C) 2017-2017 Bareos GmbH & Co. KG +# Copyright (C) 2017-2018 Bareos GmbH & Co. KG # # This program is Free Software; you can redistribute it and/or # modify it under the terms of version three of the GNU Affero General Public @@ -73,7 +73,9 @@ INCLUDE(BareosExtractVersionInfo) INCLUDE(BareosFindAllLibraries) - +IF (NOT ${OPENSSL_FOUND}) + MESSAGE(FATAL_ERROR "FATAL ERROR: OpenSSL is required but was not found.") +ENDIF() IF (coverage) diff --git a/core/cmake/BareosFindAllLibraries.cmake b/core/cmake/BareosFindAllLibraries.cmake index 9ce6a65402e..44c58d016c4 100644 --- a/core/cmake/BareosFindAllLibraries.cmake +++ b/core/cmake/BareosFindAllLibraries.cmake @@ -1,6 +1,6 @@ # BAREOS�� - Backup Archiving REcovery Open Sourced # -# Copyright (C) 2017-2017 Bareos GmbH & Co. KG +# Copyright (C) 2017-2018 Bareos GmbH & Co. KG # # This program is Free Software; you can redistribute it and/or # modify it under the terms of version three of the GNU Affero General Public @@ -45,7 +45,6 @@ if (${OPENSSL_FOUND}) SET(HAVE_OPENSSL 1) endif() - INCLUDE(BareosFindLibraryAndHeaders) BareosFindLibraryAndHeaders("fastlz" "fastlzlib.h")