diff options
author | Simon Warta <[email protected]> | 2015-06-26 20:20:32 +0200 |
---|---|---|
committer | Simon Warta <[email protected]> | 2015-07-03 10:33:45 +0200 |
commit | f472b8fc61accbbaa6a36af9d2d20b0fde37a1a2 (patch) | |
tree | 8e71c24da6f7f5b037024741105ca392369e590a /src/cmd/speed.cpp | |
parent | cd9037e29f32197b9c37ef7bec955ac2372b543b (diff) |
Make Botan compile when only some modules are enabled
Fixes #146.
Diffstat (limited to 'src/cmd/speed.cpp')
-rw-r--r-- | src/cmd/speed.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/cmd/speed.cpp b/src/cmd/speed.cpp index 5e12ff3bc..eea3a7c60 100644 --- a/src/cmd/speed.cpp +++ b/src/cmd/speed.cpp @@ -4,16 +4,20 @@ * Botan is released under the Simplified BSD License (see license.txt) */ -#include "speed.h" #include "apps.h" + +#if defined(BOTAN_HAS_RUNTIME_BENCHMARKING) + +#include "speed.h" #include <iostream> #include <iomanip> #include <botan/benchmark.h> -#include <botan/aead.h> #include <botan/auto_rng.h> +#include <botan/cipher_mode.h> #include <botan/parsing.h> #include <botan/symkey.h> +#include <botan/transform.h> #include <botan/hex.h> #include <chrono> @@ -188,7 +192,9 @@ void bench_algo(const std::string& algo, return; } +#if defined(BOTAN_HAS_PUBLIC_KEY_CRYPTO) bench_pk(rng, algo, seconds); +#endif } int speed(int argc, char* argv[]) @@ -242,3 +248,4 @@ int speed(int argc, char* argv[]) REGISTER_APP(speed); } +#endif // BOTAN_HAS_RUNTIME_BENCHMARKING |