From 970f374ea689c33321760ba62cfcad401d32521d Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Thu, 22 Apr 2021 12:42:32 +0100 Subject: [PATCH] Fix the SHA-NI cmake-time check. When preparing commit fca13a17b160da3, I redesigned the cmake test function at the last minute, and apparently didn't quite get all the call sites correctly rewritten. This one still omitted some of the argument-type keywords, and had an obsolete parameter giving an explicit name for a sub-library, which I later decided wasn't needed. --- crypto/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crypto/CMakeLists.txt b/crypto/CMakeLists.txt index 917614be..7d11f444 100644 --- a/crypto/CMakeLists.txt +++ b/crypto/CMakeLists.txt @@ -117,8 +117,8 @@ if(HAVE_WMMINTRIN_H) #include ${include_shaintrin} volatile __m128i r, a, b, c; - int main(void) { r = _mm_sha256rnds2_epu32(a, b, c); } - " sha-ni sha256-ni.c sha1-ni.c) + int main(void) { r = _mm_sha256rnds2_epu32(a, b, c); }" + ADD_SOURCES_IF_SUCCESSFUL sha256-ni.c sha1-ni.c) endif() # ----------------------------------------------------------------------