From 1994520e75e581f3e8899779f6f70961258e6c0d Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Sat, 2 Nov 2019 00:48:59 +0100 Subject: [PATCH] Windows: when building for EFI bootloader, don't make calls to RDRAND/RDSEED functions since we don't link against their implementation in EFI bootloader --- src/Crypto/cpu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Crypto/cpu.c b/src/Crypto/cpu.c index 78cc715a..53912799 100644 --- a/src/Crypto/cpu.c +++ b/src/Crypto/cpu.c @@ -387,7 +387,7 @@ void DetectX86Features() } } } - +#ifndef _UEFI /* Add check fur buggy RDRAND (AMD Ryzen case) even if we always use RDSEED instead of RDRAND when RDSEED available */ if (g_hasRDRAND) { @@ -412,6 +412,7 @@ void DetectX86Features() g_hasRDSEED = 0; } } +#endif if (!g_cacheLineSize) g_cacheLineSize = CRYPTOPP_L1_CACHE_LINE_SIZE;