Skip to content

build: support linux-arm64 build of wasm2wat - #2035

Merged
Benoît Cortier (CBenoit) merged 1 commit into
Devolutions:masterfrom
jeremie-stripe:jeremie-fix-wasm-build-arm64
Sep 29, 2026
Merged

Benoît Cortier (CBenoit) merged 1 commit into
Devolutions:masterfrom
jeremie-stripe:jeremie-fix-wasm-build-arm64

Conversation

@jeremie-stripe

@jeremie-stripe Jérémie Laval (jeremie-stripe) commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Extend the logic that downloads the wasm2wat tool from wabt to support linux-arm64 as a target (previously hardcoded to linux-x64).

This is used to validate the wasm build.

Validated this work on my linux-arm64 machine by running:

$ cargo xtask wasm install
    Finished `dev` profile [optimized + debuginfo] target(s) in 0.17s
     Running `target/debug/xtask wasm install`
::group::WASM-INSTALL
$ rustup target add wasm32-unknown-unknown
info: component 'rust-std' for target 'wasm32-unknown-unknown' is up to date
Installing wasm2wat in local root...
$ curl --location --remote-header-name https://github.com/WebAssembly/wabt/releases/download/1.0.41/wabt-1.0.41-linux-arm64.tar.gz --output wabt.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 5013k  100 5013k    0     0  11.9M      0 --:--:-- --:--:-- --:--:-- 11.9M
$ tar xf wabt.tar.gz -C ./wabt --strip-components 1
WASM-INSTALL: 655.47ms
::endgroup::

$ cargo xtask wasm check -v
    Finished `dev` profile [optimized + debuginfo] target(s) in 0.19s
     Running `target/debug/xtask wasm check -v`
[...]
::group::WASM-CHECK
Check ironrdp-web
$ [...]/jeremie/.rustup/toolchains/1.94.1-aarch64-unknown-linux-gnu/bin/cargo rustc --locked --target wasm32-unknown-unknown --package ironrdp-web --lib --crate-type cdylib
    Finished `dev` profile [optimized + debuginfo] target(s) in 0.28s
$ wasm2wat --version
1.0.41
Listing folder ./target/:
- [...]/IronRDP/./target/.rustc_info.json
- [...]/IronRDP/./target/CACHEDIR.TAG
- [...]/IronRDP/./target/debug
- [...]/IronRDP/./target/release
- [...]/IronRDP/./target/tmp
- [...]/IronRDP/./target/wasm32-unknown-unknown
Listing folder ./target/wasm32-unknown-unknown/debug/:
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/.cargo-lock
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/.fingerprint
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/build
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/deps
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/examples
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/incremental
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/ironrdp_web.d
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/ironrdp_web.wasm
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/libironrdp_web.d
- [...]/IronRDP/./target/wasm32-unknown-unknown/debug/libironrdp_web.rlib
Listing folder .cargo/local_root/bin:
- [...]/IronRDP/.cargo/local_root/bin/cargo-fuzz
- [...]/IronRDP/.cargo/local_root/bin/cargo-hack
- [...]/IronRDP/.cargo/local_root/bin/typos
- [...]/IronRDP/.cargo/local_root/bin/wasm-pack
- [...]/IronRDP/.cargo/local_root/bin/wasm-pack.stamp
- [...]/IronRDP/.cargo/local_root/bin/wasm2wat
All good!
WASM-CHECK: 1.65s
::endgroup::

(Redacted some section of output since they were not relevant and contained private details)

I hit this issue trying to validate this PR #2004

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The targeted platform selection is correct and preserves existing behavior elsewhere.

Review effort: Balanced
Findings: None

What changed in this PR

Adds Linux ARM64 support when installing wasm2wat for WASM validation.

Changes:

  • Selects WABT’s linux-arm64 artifact on AArch64 Linux hosts.
  • Retains linux-x64 for other Linux architectures.

No material issues identified; protocol and documentation passes were not applicable.

File Description
xtask/​src/​wasm.rs Selects the architecture-appropriate Linux WABT archive.

[!NOTE]
LLM-assisted content (no human feedback).

@github-actions github-actions Bot added risk/low Self-contained change with no cross-crate behavioral effect scope/tooling Build, CI, release, or developer tooling size/XS Size: up to 49 counted lines and 2 files labels Sep 28, 2026

@CBenoit Benoît Cortier (CBenoit) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

@CBenoit
Benoît Cortier (CBenoit) merged commit c003152 into Devolutions:master Sep 29, 2026
52 of 54 checks passed

This branch was successfully deployed

1 active deployment
llm-providers — 562fb831 Deployed Sep 28, 2026 by jeremie-stripe via Classify pull request #949
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk/low Self-contained change with no cross-crate behavioral effect scope/tooling Build, CI, release, or developer tooling size/XS Size: up to 49 counted lines and 2 files

Development

Successfully merging this pull request may close these issues.

3 participants