1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-29 11:41:15 +03:00

Support compilation using CLang on Windows

The Microsoft-only equivalent to GCC's `cpuid.h` is `intrin.h`. CLang contains both, but neither is directly included in Win32 builds, causing `__cpuid` to not be defined. This explicitly includes `intrin.h` when `cpuid.h` is not used.

Signed-off-by: SlugFiller <5435495+SlugFiller@users.noreply.github.com>
This commit is contained in:
SlugFiller
2023-05-22 06:31:45 +03:00
committed by GitHub
parent 1873d3bfc2
commit 5ca3f0ba00

View File

@ -35,6 +35,8 @@
#if MBEDTLS_AESNI_HAVE_CODE == 2
#if !defined(_WIN32)
#include <cpuid.h>
#else
#include <intrin.h>
#endif
#include <immintrin.h>
#endif