]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crypto: fix cmake error '#elif with no expression'
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Thu, 7 May 2015 11:23:37 +0000 (13:23 +0200)
committerDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Thu, 7 May 2015 11:23:37 +0000 (13:23 +0200)
It needs to be '#elif defined()' to work with cmake.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
src/auth/Crypto.cc
src/common/ceph_crypto.cc
src/common/ceph_crypto.h

index 5223f5a48e88968999bbdc6fc6dfd963f75e3dfa..24c4bd0d5617d3c070962bfd5ddb3868f1995373 100644 (file)
@@ -17,7 +17,7 @@
 # include <cryptopp/modes.h>
 # include <cryptopp/aes.h>
 # include <cryptopp/filters.h>
-#elif USE_NSS
+#elif defined(USE_NSS)
 # include <nspr.h>
 # include <nss.h>
 # include <pk11pub.h>
@@ -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
index eb46672b917a82a79145aecdff0daa9ca0278035..99c25150dcc11d0db41349c54eb4b1ceea3e2090 100644 (file)
@@ -35,7 +35,7 @@ ceph::crypto::HMACSHA1::~HMACSHA1()
 {
 }
 
-#elif USE_NSS
+#elif defined(USE_NSS)
 
 // for SECMOD_RestartModules()
 #include <secmod.h>
index 686efb4896121f2fafae856eea6388b6afcfabbd..10055f6bcc50feba1dd144009d9901e354b800b8 100644 (file)
@@ -11,9 +11,9 @@
 #ifdef USE_CRYPTOPP
 # define CRYPTOPP_ENABLE_NAMESPACE_WEAK 1
 #include <string.h>
-# include <cryptopp/md5.h>
-# include <cryptopp/sha.h>
-# include <cryptopp/hmac.h>
+#include <cryptopp/md5.h>
+#include <cryptopp/sha.h>
+#include <cryptopp/hmac.h>
 
 // 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 <nss.h>
 # include <pk11pub.h>