aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/build-data/os/windows.txt1
-rw-r--r--src/entropy/hres_timer/hres_timer.cpp5
2 files changed, 3 insertions, 3 deletions
diff --git a/src/build-data/os/windows.txt b/src/build-data/os/windows.txt
index e72931c98..59e3ec072 100644
--- a/src/build-data/os/windows.txt
+++ b/src/build-data/os/windows.txt
@@ -12,6 +12,7 @@ install_cmd_exec "copy"
<target_features>
win32_virtual_lock
+win32_query_perf_counter
</target_features>
<supports_shared>
diff --git a/src/entropy/hres_timer/hres_timer.cpp b/src/entropy/hres_timer/hres_timer.cpp
index 0f75583ef..e6cc102ed 100644
--- a/src/entropy/hres_timer/hres_timer.cpp
+++ b/src/entropy/hres_timer/hres_timer.cpp
@@ -8,7 +8,7 @@
#include <botan/hres_timer.h>
#include <botan/cpuid.h>
-#if defined(BOTAN_TARGET_OS_IS_WINDOWS)
+#if defined(BOTAN_TARGET_OS_HAS_QUERY_PERF_COUNTER)
#include <windows.h>
#endif
@@ -19,8 +19,7 @@ namespace Botan {
*/
void High_Resolution_Timestamp::poll(Entropy_Accumulator& accum)
{
- // If Windows, grab the Performance Counter (usually TSC or PIT)
-#if defined(BOTAN_TARGET_OS_IS_WINDOWS)
+#if defined(BOTAN_TARGET_OS_HAS_QUERY_PERF_COUNTER)
LARGE_INTEGER tv;
::QueryPerformanceCounter(&tv);
accum.add(tv.QuadPart, 0);