aboutsummaryrefslogtreecommitdiff
path: root/patches/patch-i386-crypto-cpu-caps.c.patch
blob: 0642582f7207a4284bc79418d38fdf4330e81031 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
--- crypto/arch/i386/crypto_cpu_caps.c.orig	Mon Jun 16 10:38:27 2025
+++ crypto/arch/i386/crypto_cpu_caps.c	Mon Jun 16 10:38:39 2025
@@ -37,7 +37,7 @@ cpuid(uint32_t eax, uint32_t *out_eax, uint32_t *out_e
 {
 	uint32_t ebx = 0, ecx = 0, edx = 0;
 
-#ifndef OPENSSL_NO_ASM
+#if defined(__GNUC__) && !defined(OPENSSL_NO_ASM)
 	__asm__ ("cpuid": "+a"(eax), "+b"(ebx), "+c"(ecx), "+d"(edx));
 #else
 	eax = 0;
@@ -58,7 +58,7 @@ xgetbv(uint32_t ecx, uint32_t *out_eax, uint32_t *out_
 {
 	uint32_t eax = 0, edx = 0;
 
-#ifndef OPENSSL_NO_ASM
+#if defined(__GNUC__) && !defined(OPENSSL_NO_ASM)
 	__asm__ ("xgetbv": "+a"(eax), "+c"(ecx), "+d"(edx));
 #endif