From c2b3775c235055059c34b16b4cd0fb72caa2a587 Mon Sep 17 00:00:00 2001 From: Bruno Verachten Date: Sun, 5 Apr 2026 12:58:56 +0200 Subject: [PATCH] feat: add riscv64 architecture support Map Node.js 'riscv64' arch to 'riscv64gc' to match the release asset naming convention used by wasmtime, wasm-tools, and wit-bindgen. wasmtime v43+ ships riscv64gc-linux binaries; this allows the setup action to install wasmtime on riscv64 runners (e.g. RISE Project ubuntu-24.04-riscv runners). Signed-off-by: Bruno Verachten --- dist/wasm-tools/setup/index.js | 2 ++ dist/wasmtime/setup/index.js | 2 ++ dist/wit-bindgen/setup/index.js | 2 ++ src/system.ts | 2 ++ 4 files changed, 8 insertions(+) diff --git a/dist/wasm-tools/setup/index.js b/dist/wasm-tools/setup/index.js index 35e609b..242bce4 100644 --- a/dist/wasm-tools/setup/index.js +++ b/dist/wasm-tools/setup/index.js @@ -16984,6 +16984,8 @@ function getArch() { return 'aarch64'; case 'x64': return 'x86_64'; + case 'riscv64': + return 'riscv64gc'; default: throw new Error(`Unsupported operating system architecture: ${arch}`); } diff --git a/dist/wasmtime/setup/index.js b/dist/wasmtime/setup/index.js index 0cd1a7c..235e163 100644 --- a/dist/wasmtime/setup/index.js +++ b/dist/wasmtime/setup/index.js @@ -16984,6 +16984,8 @@ function getArch() { return 'aarch64'; case 'x64': return 'x86_64'; + case 'riscv64': + return 'riscv64gc'; default: throw new Error(`Unsupported operating system architecture: ${arch}`); } diff --git a/dist/wit-bindgen/setup/index.js b/dist/wit-bindgen/setup/index.js index 031f7f9..c63d256 100644 --- a/dist/wit-bindgen/setup/index.js +++ b/dist/wit-bindgen/setup/index.js @@ -16984,6 +16984,8 @@ function getArch() { return 'aarch64'; case 'x64': return 'x86_64'; + case 'riscv64': + return 'riscv64gc'; default: throw new Error(`Unsupported operating system architecture: ${arch}`); } diff --git a/src/system.ts b/src/system.ts index 7a10ed9..bada518 100644 --- a/src/system.ts +++ b/src/system.ts @@ -29,6 +29,8 @@ export function getArch(): string { return 'aarch64' case 'x64': return 'x86_64' + case 'riscv64': + return 'riscv64gc' default: throw new Error(`Unsupported operating system architecture: ${arch}`) }