From b07a4451a3eae334153e61d6a536266e162efa2d Mon Sep 17 00:00:00 2001 From: Danny Willems Date: Fri, 3 Oct 2025 11:28:23 +0200 Subject: [PATCH 1/3] CI/tests: add build-wasm --- .github/workflows/tests.yaml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index ba06d445e..9728b255d 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -284,6 +284,27 @@ jobs: path: target/release/tests retention-days: 7 + build-wasm: + timeout-minutes: 60 + runs-on: ubuntu-22.04 + steps: + - name: Git checkout + uses: actions/checkout@v5 + + - name: Setup build dependencies + uses: ./.github/actions/setup-build-deps + + - name: Setup Rust + uses: ./.github/actions/setup-rust + with: + toolchain: nightly + cache-prefix: build-wasm-v0 + + - name: Setup wasm tooling + run: make setup-wasm + + - name: Build WebAssembly node + run: make build-wasm p2p-scenario-tests: needs: [build-tests, build-tests-webrtc] From 4953988476412861a0b9a77068fdedb012857c91 Mon Sep 17 00:00:00 2001 From: Danny Willems Date: Fri, 10 Oct 2025 13:26:23 +0200 Subject: [PATCH 2/3] CHANGELOG: add description for patch 1497 --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 118808c5a..f49da0820 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -60,6 +60,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ([#1513](https://github.com/o1-labs/mina-rust/pull/1513)) - **scan_state**: refactorize `transaction_logic.rs` in smaller modules ([#1515](https://github.com/o1-labs/mina-rust/pull/1515)) +- **CI/tests**: run the step `build-wasm` for each push and PR to `develop` + ([#1497](https://github.com/o1-labs/mina-rust/pull/1497)) ## v0.17.0 From ac20446369367e87f327d35e2400913dcca12e4b Mon Sep 17 00:00:00 2001 From: Danny Willems Date: Fri, 10 Oct 2025 14:02:34 +0200 Subject: [PATCH 3/3] CI: split arguments of rustflags --- .github/workflows/build-macos-13.yaml | 1 + .github/workflows/build-macos-14.yaml | 1 + .github/workflows/build-macos-15.yaml | 1 + .github/workflows/build-macos-latest.yaml | 1 + .github/workflows/build-reusable.yaml | 15 +++++++++++++-- .github/workflows/tests.yaml | 2 +- 6 files changed, 18 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-macos-13.yaml b/.github/workflows/build-macos-13.yaml index 5b5ab3848..2f63e177e 100644 --- a/.github/workflows/build-macos-13.yaml +++ b/.github/workflows/build-macos-13.yaml @@ -16,3 +16,4 @@ jobs: os: macos-13 cache-prefix: macos-13- build-wasm: true + rustflags: "-C link-args=-Wl,-undefined,dynamic_lookup" diff --git a/.github/workflows/build-macos-14.yaml b/.github/workflows/build-macos-14.yaml index ef1a38dc9..6b30ac779 100644 --- a/.github/workflows/build-macos-14.yaml +++ b/.github/workflows/build-macos-14.yaml @@ -16,3 +16,4 @@ jobs: os: macos-14 cache-prefix: macos-14- build-wasm: true + rustflags: "-C link-args=-Wl,-undefined,dynamic_lookup" diff --git a/.github/workflows/build-macos-15.yaml b/.github/workflows/build-macos-15.yaml index 2f5ffb91d..d9b35b193 100644 --- a/.github/workflows/build-macos-15.yaml +++ b/.github/workflows/build-macos-15.yaml @@ -16,3 +16,4 @@ jobs: os: macos-15 cache-prefix: macos-15- build-wasm: true + rustflags: "-C link-args=-Wl,-undefined,dynamic_lookup" diff --git a/.github/workflows/build-macos-latest.yaml b/.github/workflows/build-macos-latest.yaml index b6c52dc3d..f711bdca8 100644 --- a/.github/workflows/build-macos-latest.yaml +++ b/.github/workflows/build-macos-latest.yaml @@ -16,3 +16,4 @@ jobs: os: macos-latest cache-prefix: macos-latest- build-wasm: true + rustflags: "-C link-args=-Wl,-undefined,dynamic_lookup" diff --git a/.github/workflows/build-reusable.yaml b/.github/workflows/build-reusable.yaml index dc5caf4d0..4e96f454e 100644 --- a/.github/workflows/build-reusable.yaml +++ b/.github/workflows/build-reusable.yaml @@ -22,18 +22,25 @@ on: type: boolean default: false description: "Whether to build WASM targets" + rustflags: + required: false + type: string + default: "" + description: "Additional RUSTFLAGS to append (e.g., macOS-specific linker flags)" env: CARGO_TERM_COLOR: always RUST_BACKTRACE: full MINA_PANIC_ON_BUG: true CARGO_INCREMENTAL: 1 - RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off -C link-args=-Wl,-undefined,dynamic_lookup" + RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off" jobs: build: timeout-minutes: 60 runs-on: ${{ inputs.os }} + env: + RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off ${{ inputs.rustflags }}" steps: - name: Git checkout uses: actions/checkout@v5 @@ -75,6 +82,8 @@ jobs: build-tests: timeout-minutes: 60 runs-on: ${{ inputs.os }} + env: + RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off ${{ inputs.rustflags }}" steps: - name: Git checkout uses: actions/checkout@v5 @@ -99,6 +108,8 @@ jobs: build-tests-webrtc: timeout-minutes: 60 runs-on: ${{ inputs.os }} + env: + RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off ${{ inputs.rustflags }}" steps: - name: Git checkout uses: actions/checkout@v5 @@ -144,4 +155,4 @@ jobs: - name: Release build run: make build-wasm env: - RUSTFLAGS: "" \ No newline at end of file + RUSTFLAGS: "" diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 9728b255d..5619c1208 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -16,7 +16,7 @@ env: RUST_BACKTRACE: full MINA_PANIC_ON_BUG: true CARGO_INCREMENTAL: 1 - RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off -C link-args=-Wl,-undefined,dynamic_lookup" + RUSTFLAGS: "-C overflow-checks=off -C debug-assertions=off" concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}