diff options
author | Simon Warta <[email protected]> | 2015-07-03 18:11:13 +0200 |
---|---|---|
committer | Simon Warta <[email protected]> | 2015-07-03 18:11:13 +0200 |
commit | e087a695ffaa016651944820fab63760cb9eae27 (patch) | |
tree | 21370311be2f50b339c2c035ed8e1d8176c677e4 | |
parent | ae94396329f583d0999d4086936811f68bddd59b (diff) | |
parent | a69d61aa98550ae2b2bcac88eeb94ed49da3b916 (diff) |
Merge pull request #166 from webmaster128/dlies-compile-fixes
Dlies compile fixes
-rw-r--r-- | src/cmd/speed_pk.cpp | 6 | ||||
-rw-r--r-- | src/tests/test_dlies.cpp | 8 | ||||
-rw-r--r-- | src/tests/tests.cpp | 1 |
3 files changed, 12 insertions, 3 deletions
diff --git a/src/cmd/speed_pk.cpp b/src/cmd/speed_pk.cpp index dc0ee79da..035b9a3af 100644 --- a/src/cmd/speed_pk.cpp +++ b/src/cmd/speed_pk.cpp @@ -47,7 +47,7 @@ #include <botan/elgamal.h> #endif -#if defined(BOTAN_HAS_DLIES) +#if defined(BOTAN_HAS_DLIES) && defined(BOTAN_HAS_KDF2) #include <botan/dlies.h> #include <botan/kdf2.h> #include <botan/hmac.h> @@ -614,7 +614,7 @@ void benchmark_dh(RandomNumberGenerator& rng, } #endif -#if defined(BOTAN_HAS_DIFFIE_HELLMAN) && defined(BOTAN_HAS_DLIES) +#if defined(BOTAN_HAS_DIFFIE_HELLMAN) && defined(BOTAN_HAS_DLIES) && defined(BOTAN_HAS_KDF2) void benchmark_dlies(RandomNumberGenerator& rng, double seconds, Benchmark_Report& report) @@ -850,7 +850,7 @@ void bench_pk(RandomNumberGenerator& rng, benchmark_dh(rng, seconds, report); #endif -#if defined(BOTAN_HAS_DIFFIE_HELLMAN) && defined(BOTAN_HAS_DLIES) +#if defined(BOTAN_HAS_DIFFIE_HELLMAN) && defined(BOTAN_HAS_DLIES) && defined(BOTAN_HAS_KDF2) if(algo == "All" || algo == "DLIES") benchmark_dlies(rng, seconds, report); #endif diff --git a/src/tests/test_dlies.cpp b/src/tests/test_dlies.cpp index 8fc1f31a0..40b48c61f 100644 --- a/src/tests/test_dlies.cpp +++ b/src/tests/test_dlies.cpp @@ -8,6 +8,8 @@ #if defined(BOTAN_HAS_DLIES) +#if defined(BOTAN_HAS_DIFFIE_HELLMAN) + #include "test_pubkey.h" #include <iostream> @@ -86,6 +88,12 @@ size_t test_dlies() #else +UNTESTED_WARNING(dlies); + +#endif // BOTAN_HAS_DIFFIE_HELLMAN + +#else + SKIP_TEST(dlies); #endif // BOTAN_HAS_DLIES diff --git a/src/tests/tests.cpp b/src/tests/tests.cpp index 539737437..b7cfd2ecc 100644 --- a/src/tests/tests.cpp +++ b/src/tests/tests.cpp @@ -56,6 +56,7 @@ size_t run_tests(const std::vector<test_fn>& tests) } // Summary for test suite + std::cout << "===============" << std::endl; test_report("Tests", 0, fails); return fails; |