hc
2023-11-06 15ade055295d13f95d49e3d99b09f3bbfb4a43e7
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
From daf2e222903bacf85f27dfb0fffc4459bbf58b77 Mon Sep 17 00:00:00 2001
From: =?utf-8?q?Ga=C3=ABl=20PORTAY?= <gael.portay@savoirfairelinux.com>
Date: Sun, 10 Jun 2018 08:23:50 -0400
Subject: [PATCH] Detect 32-bits armv8-a architecture
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
 
These toolchains define __ARM_ARCH_8A__ (for ARM architecture version)
and __arm__ (for 32-bits word-size; __aarch64__ for 64-bits).
 
This commit catches this new architecture (armv8a) within a #ifdef/#endif
inside the if statement dedicated for 32-bits ARM detection. See commit
from WebKit [1] and [2].
 
Fixes:
 
   In file included from ../3rdparty/javascriptcore/JavaScriptCore/config.h:26,
                    from ../3rdparty/javascriptcore/JavaScriptCore/pcre/pcre_compile.cpp:44:
   ../3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h:370:6: error: #error "Not supported ARM architecture"
    #    error "Not supported ARM architecture"
         ^~~~~
 
[1]: https://github.com/WebKit/webkit/commit/313d9fc4bdd2f020a5d0cf834c3c61982f161ebb
[2]: https://github.com/WebKit/webkit/commit/98f0de0709786f5d9b09dfd5908266990eb909d6
 
Signed-off-by: GaĆ«l PORTAY <gael.portay@savoirfairelinux.com>
---
 src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h | 4 ++++
 1 file changed, 4 insertions(+)
 
diff --git a/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h b/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
index 00caa6d..c4b758e 100644
--- a/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
+++ b/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
@@ -306,6 +306,10 @@
     || defined(__ARM_ARCH_7R__)
 #define WTF_ARM_ARCH_VERSION 7
 
+#elif defined(__ARM_ARCH_8__) \
+    || defined(__ARM_ARCH_8A__)
+#define WTF_ARM_ARCH_VERSION 8
+
 /* RVCT sets _TARGET_ARCH_ARM */
 #elif defined(__TARGET_ARCH_ARM)
 #define WTF_ARM_ARCH_VERSION __TARGET_ARCH_ARM
-- 
2.17.1