Commit 282b2b939504de790f55a4c3965ff79f48c6f2e7

Ozkan Sezer 2019-06-25T11:47:02

define __ARM_NEON for Windows only if _M_ARM or _M_ARM64 is defined. fixes Visual Studio builds.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
diff --git a/include/SDL_cpuinfo.h b/include/SDL_cpuinfo.h
index 1e12d7e..296df01 100644
--- a/include/SDL_cpuinfo.h
+++ b/include/SDL_cpuinfo.h
@@ -70,13 +70,13 @@
 #    if defined(_M_ARM)
 #      include <armintr.h>
 #      include <arm_neon.h>
+#      define __ARM_NEON 1 /* Set __ARM_NEON so that it can be used elsewhere, at compile time */
 #    endif
 #    if defined (_M_ARM64)
 #      include <armintr.h>
 #      include <arm_neon.h>
+#      define __ARM_NEON 1 /* Set __ARM_NEON so that it can be used elsewhere, at compile time */
 #    endif
-/* Set __ARM_NEON so that it can be used elsewhere, at compile time */
-#    define __ARM_NEON 1
 #  endif
 #endif
 #if defined(__3dNOW__) && !defined(SDL_DISABLE_MM3DNOW_H)