diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 1a7cdde..853a729 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -22,6 +22,9 @@ jobs: run: rustup component add rustfmt clippy - name: Install thumbv7em-none-eabihf target run: rustup target add thumbv7em-none-eabihf + - name: Install wasm32-unknown-unknown target + # ci-test.sh builds the reader and clawhdf5-wasm for the browser. + run: rustup target add wasm32-unknown-unknown - name: Install Python interop dependencies # The interop suites used to skip silently when python3/h5py were # missing, so they never ran in CI. Install them and make a missing diff --git a/scripts/ci-test.sh b/scripts/ci-test.sh index 1d7a7f9..6cad171 100755 --- a/scripts/ci-test.sh +++ b/scripts/ci-test.sh @@ -106,6 +106,14 @@ no_c_in_default_build() { } run_step "no C in the default build (core crates)" no_c_in_default_build +# The reader in the browser: the facade's read path must build for +# wasm32-unknown-unknown (no mmap, no threads, no file system). Needs +# `rustup target add wasm32-unknown-unknown`. +run_step "wasm32 build (clawhdf5, no default features)" cargo build \ + -p clawhdf5 \ + --target wasm32-unknown-unknown \ + --no-default-features + # The workspace declares a minimum Rust version (rust-version in Cargo.toml); # check that it really builds there, so the README badge and the manifests # cannot drift from the truth. Separate target dir: a different toolchain