Skip to content

Commit

Permalink
mozjs-128: Fix riscv arch specification in triplets
Browse files Browse the repository at this point in the history
Rust needs it these days

Signed-off-by: Khem Raj <raj.khem@gmail.com>
  • Loading branch information
kraj committed Jan 7, 2025
1 parent 4a309a2 commit 9582c1e
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 0 deletions.
30 changes: 30 additions & 0 deletions meta-oe/recipes-extended/mozjs/mozjs-128/riscv.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
Recognise riscv64gc and riscv32gc as valid architectures

Rust uses above for architecture in tuples

Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
--- a/python/mozbuild/mozbuild/test/configure/test_toolchain_configure.py
+++ b/python/mozbuild/mozbuild/test/configure/test_toolchain_configure.py
@@ -1327,6 +1327,10 @@ class LinuxCrossCompileToolchainTest(Bas
"mips-unknown-linux-gnu": big_endian + {"__mips__": 1},
"riscv32-unknown-linux-gnu": little_endian + {"__riscv": 1, "__riscv_xlen": 32},
"riscv64-unknown-linux-gnu": little_endian + {"__riscv": 1, "__riscv_xlen": 64},
+ "riscv32gc-unknown-linux-gnu": little_endian
+ + {"__riscv": 1, "__riscv_xlen": 32},
+ "riscv64gc-unknown-linux-gnu": little_endian
+ + {"__riscv": 1, "__riscv_xlen": 64},
"sh4-unknown-linux-gnu": little_endian + {"__sh__": 1},
}

--- a/build/autoconf/config.sub
+++ b/build/autoconf/config.sub
@@ -1236,7 +1236,7 @@ case $cpu-$vendor in
| powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \
| pru \
| pyramid \
- | riscv | riscv32 | riscv32be | riscv64 | riscv64be \
+ | riscv | riscv32 | riscv32be | riscv32gc | riscv64 | riscv64be | riscv64gc \
| rl78 | romp | rs6000 | rx \
| s390 | s390x \
| score \
1 change: 1 addition & 0 deletions meta-oe/recipes-extended/mozjs/mozjs-128_128.5.2.bb
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ SRC_URI = "https://archive.mozilla.org/pub/firefox/releases/${PV}esr/source/fire
file://0001-add-arm-to-list-of-mozinline.patch \
file://armv5.patch \
file://0001-Link-with-icu-uc-to-fix-build-with-ICU-76.patch \
file://riscv.patch \
"
SRC_URI[sha256sum] = "25d633eb81499cbda44b8c64fa1c1a5879d55024b864ef495d4997154d68358f"

Expand Down

0 comments on commit 9582c1e

Please sign in to comment.