diff options
Diffstat (limited to 'meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch')
-rw-r--r-- | meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch | 38 |
1 files changed, 9 insertions, 29 deletions
diff --git a/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch b/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch index 4354a9dee..0a4148561 100644 --- a/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch +++ b/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch | |||
@@ -4,8 +4,6 @@ Upstream-Status: Submitted [https://bugzilla.mozilla.org/show_bug.cgi?id=1318905 | |||
4 | 4 | ||
5 | Signed-off-by: Ricardo Salveti <ricardo@foundries.io> | 5 | Signed-off-by: Ricardo Salveti <ricardo@foundries.io> |
6 | 6 | ||
7 | diff --git a/build/autoconf/config.guess b/build/autoconf/config.guess | ||
8 | index d5d667d..1277a86 100755 | ||
9 | --- a/build/autoconf/config.guess | 7 | --- a/build/autoconf/config.guess |
10 | +++ b/build/autoconf/config.guess | 8 | +++ b/build/autoconf/config.guess |
11 | @@ -1029,6 +1029,9 @@ EOF | 9 | @@ -1029,6 +1029,9 @@ EOF |
@@ -18,39 +16,21 @@ index d5d667d..1277a86 100755 | |||
18 | s390:Linux:*:* | s390x:Linux:*:*) | 16 | s390:Linux:*:* | s390x:Linux:*:*) |
19 | echo ${UNAME_MACHINE}-ibm-linux-${LIBC} | 17 | echo ${UNAME_MACHINE}-ibm-linux-${LIBC} |
20 | exit ;; | 18 | exit ;; |
21 | diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure | ||
22 | index 6fe6591..56e6730 100644 | ||
23 | --- a/build/moz.configure/init.configure | 19 | --- a/build/moz.configure/init.configure |
24 | +++ b/build/moz.configure/init.configure | 20 | +++ b/build/moz.configure/init.configure |
25 | @@ -362,6 +362,9 @@ def split_triplet(triplet): | 21 | @@ -658,6 +658,9 @@ def split_triplet(triplet, allow_unknown |
26 | elif cpu.startswith('aarch64'): | 22 | elif cpu == 'sh4': |
27 | canonical_cpu = 'aarch64' | 23 | canonical_cpu = 'sh4' |
28 | endianness = 'little' | 24 | endianness = 'little' |
29 | + elif cpu in ('riscv32', 'riscv64'): | 25 | + elif cpu in ('riscv32', 'riscv64'): |
30 | + canonical_cpu = cpu | 26 | + canonical_cpu = cpu |
31 | + endianness = 'little' | 27 | + endianness = 'little' |
32 | else: | 28 | elif allow_unknown: |
33 | die('Unknown CPU type: %s' % cpu) | 29 | canonical_cpu = cpu |
34 | 30 | endianness = 'unknown' | |
35 | diff --git a/mfbt/double-conversion/utils.h b/mfbt/double-conversion/utils.h | ||
36 | index 15dd4bf..4f37218 100644 | ||
37 | --- a/mfbt/double-conversion/utils.h | ||
38 | +++ b/mfbt/double-conversion/utils.h | ||
39 | @@ -60,7 +60,8 @@ | ||
40 | defined(__sparc__) || defined(__sparc) || defined(__s390__) || \ | ||
41 | defined(__SH4__) || defined(__alpha__) || \ | ||
42 | defined(_MIPS_ARCH_MIPS32R2) || \ | ||
43 | - defined(__AARCH64EL__) || defined(__aarch64__) | ||
44 | + defined(__AARCH64EL__) || defined(__aarch64__) || \ | ||
45 | + defined(__riscv) | ||
46 | #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1 | ||
47 | #elif defined(_M_IX86) || defined(__i386__) || defined(__i386) | ||
48 | #if defined(_WIN32) | ||
49 | diff --git a/python/mozbuild/mozbuild/configure/constants.py b/python/mozbuild/mozbuild/configure/constants.py | ||
50 | index dfc7cf8..4f8d666 100644 | ||
51 | --- a/python/mozbuild/mozbuild/configure/constants.py | 31 | --- a/python/mozbuild/mozbuild/configure/constants.py |
52 | +++ b/python/mozbuild/mozbuild/configure/constants.py | 32 | +++ b/python/mozbuild/mozbuild/configure/constants.py |
53 | @@ -48,6 +48,8 @@ CPU_bitness = { | 33 | @@ -50,6 +50,8 @@ CPU_bitness = { |
54 | 'mips64': 64, | 34 | 'mips64': 64, |
55 | 'ppc': 32, | 35 | 'ppc': 32, |
56 | 'ppc64': 64, | 36 | 'ppc64': 64, |
@@ -58,8 +38,8 @@ index dfc7cf8..4f8d666 100644 | |||
58 | + 'riscv64': 64, | 38 | + 'riscv64': 64, |
59 | 's390': 32, | 39 | 's390': 32, |
60 | 's390x': 64, | 40 | 's390x': 64, |
61 | 'sparc': 32, | 41 | 'sh4': 32, |
62 | @@ -79,6 +81,8 @@ CPU_preprocessor_checks = OrderedDict(( | 42 | @@ -82,6 +84,8 @@ CPU_preprocessor_checks = OrderedDict(( |
63 | ('s390', '__s390__'), | 43 | ('s390', '__s390__'), |
64 | ('ppc64', '__powerpc64__'), | 44 | ('ppc64', '__powerpc64__'), |
65 | ('ppc', '__powerpc__'), | 45 | ('ppc', '__powerpc__'), |