From 67e2caa6fe96d14c2d722156fb47fe1857e06720 Mon Sep 17 00:00:00 2001 From: Danny Al-Gaaf Date: Thu, 7 May 2015 13:23:37 +0200 Subject: [PATCH] crypto: fix cmake error '#elif with no expression' It needs to be '#elif defined()' to work with cmake. Signed-off-by: Danny Al-Gaaf --- src/auth/Crypto.cc | 4 ++-- src/common/ceph_crypto.cc | 2 +- src/common/ceph_crypto.h | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/auth/Crypto.cc b/src/auth/Crypto.cc index 5223f5a48e889..24c4bd0d5617d 100644 --- a/src/auth/Crypto.cc +++ b/src/auth/Crypto.cc @@ -17,7 +17,7 @@ # include # include # include -#elif USE_NSS +#elif defined(USE_NSS) # include # include # include @@ -197,7 +197,7 @@ public: } }; -#elif USE_NSS +#elif defined(USE_NSS) // when we say AES, we mean AES-128 # define AES_KEY_LEN 16 # define AES_BLOCK_LEN 16 diff --git a/src/common/ceph_crypto.cc b/src/common/ceph_crypto.cc index eb46672b917a8..99c25150dcc11 100644 --- a/src/common/ceph_crypto.cc +++ b/src/common/ceph_crypto.cc @@ -35,7 +35,7 @@ ceph::crypto::HMACSHA1::~HMACSHA1() { } -#elif USE_NSS +#elif defined(USE_NSS) // for SECMOD_RestartModules() #include diff --git a/src/common/ceph_crypto.h b/src/common/ceph_crypto.h index 686efb4896121..10055f6bcc50f 100644 --- a/src/common/ceph_crypto.h +++ b/src/common/ceph_crypto.h @@ -11,9 +11,9 @@ #ifdef USE_CRYPTOPP # define CRYPTOPP_ENABLE_NAMESPACE_WEAK 1 #include -# include -# include -# include +#include +#include +#include // reinclude our assert to clobber the system one # include "include/assert.h" @@ -38,7 +38,7 @@ namespace ceph { }; } } -#elif USE_NSS +#elif defined(USE_NSS) // you *must* use CRYPTO_CXXFLAGS in Makefile.am for including this include # include # include -- 2.39.5