From 76044be98d3eb0c6fc4547846590f5831744dd73 Mon Sep 17 00:00:00 2001 From: Ingo Franzki Date: Tue, 20 Oct 2020 11:53:03 +0200 Subject: [PATCH] zkey: Ensure zkey and friends are skipped with HAVE_OPENSSL=0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Building zkey-ekmfweb.so will also trigger to build libekmfweb.so, which requires OpenSSL. So, skip zkey-ekmfweb.so if HAVE_OPENSSL=0. zkey-cryptsetup also has a dependency on OpenSSL, so skip it also if HAVE_OPENSSL=0 Signed-off-by: Ingo Franzki Signed-off-by: Jan Höppner --- zkey/Makefile | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/zkey/Makefile b/zkey/Makefile index 1d38ce9d..ccb37fc8 100644 --- a/zkey/Makefile +++ b/zkey/Makefile @@ -1,10 +1,9 @@ include ../common.mak -SUB_DIRS = ekmfweb - ifneq (${HAVE_OPENSSL},0) BUILD_TARGETS += zkey INSTALL_TARGETS += install-zkey + SUB_DIRS += ekmfweb else BUILD_TARGETS += zkey-skip INSTALL_TARGETS += zkey-skip @@ -12,9 +11,14 @@ endif ifneq (${HAVE_CRYPTSETUP2},0) ifneq (${HAVE_JSONC},0) - BUILD_TARGETS += zkey-cryptsetup - INSTALL_TARGETS += install-zkey-cryptsetup - CPPFLAGS += -DHAVE_LUKS2_SUPPORT + ifneq (${HAVE_OPENSSL},0) + BUILD_TARGETS += zkey-cryptsetup + INSTALL_TARGETS += install-zkey-cryptsetup + CPPFLAGS += -DHAVE_LUKS2_SUPPORT + else + BUILD_TARGETS += zkey-cryptsetup-skip-openssl + INSTALL_TARGETS += zkey-cryptsetup-skip-openssl + endif else BUILD_TARGETS += zkey-cryptsetup-skip-jsonc INSTALL_TARGETS += zkey-cryptsetup-skip-jsonc @@ -64,6 +68,9 @@ zkey-cryptsetup-skip-cryptsetup2: zkey-cryptsetup-skip-jsonc: echo " SKIP zkey-cryptsetup due to HAVE_JSONC=0" +zkey-cryptsetup-skip-openssl: + echo " SKIP zkey-cryptsetup due to HAVE_OPENSSL=0" + all: $(BUILD_TARGETS) $(SUB_DIRS) zkey.o: zkey.c pkey.h cca.h ep11.h misc.h