Skip to content

fix: backport arm64-linux avm-transpiler cross-compilation (#20814, #20932)#21073

Closed
AztecBot wants to merge 1 commit intobackport-to-v4-stagingfrom
claudebox/596d4a62f30fd2f0-2
Closed

fix: backport arm64-linux avm-transpiler cross-compilation (#20814, #20932)#21073
AztecBot wants to merge 1 commit intobackport-to-v4-stagingfrom
claudebox/596d4a62f30fd2f0-2

Conversation

@AztecBot
Copy link
Collaborator

@AztecBot AztecBot commented Mar 3, 2026

Summary

Backports two fixes from next that enable the AVM transpiler for linux/arm64 release builds, resolving #20793aztec compile fails with "AVM Transpiler is not enabled" on linux/arm64.

Cherry-picked from:

Root cause: The zig-arm64-linux CMake preset was missing AVM_TRANSPILER_LIB, and avm-transpiler/bootstrap.sh had no arm64-linux case in build_cross. The arm64-linux bb binary was compiled without ENABLE_AVM_TRANSPILER.

Changes:

  • avm-transpiler/bootstrap.sh — add arm64-linux case to build_cross
  • barretenberg/cpp/CMakePresets.json — wire AVM_TRANSPILER_LIB for zig-arm64-linux preset
  • Makefile — add avm-transpiler-cross-arm64-linux target, fix bb-cpp-cross-arm64-linux dependency
  • barretenberg/rust/bootstrap.sh — add release function with on-the-fly binding generation
  • barretenberg/ts/scripts/copy_cross.sh — relax arch check for release context

Conflict resolution: barretenberg/rust/bootstrap.sh had a minor conflict — the release function didn't exist on v4. Resolved by accepting the full function.

Test plan

  • Native avm-transpiler build succeeds
  • Makefile targets verified: avm-transpiler-cross-arm64-linux, bb-cpp-cross-arm64-linux dependency corrected
  • CMake preset verified: zig-arm64-linux has AVM_TRANSPILER_LIB pointing to correct cross-compiled path
  • Full cross-compilation validated in release CI

Closes #20793

ClaudeBox log: http://ci.aztec-labs.com/596d4a62f30fd2f0-2

@AztecBot AztecBot added the claudebox Owned by claudebox. it can push to this PR. label Mar 3, 2026
@ludamad ludamad marked this pull request as ready for review March 3, 2026 20:00
@ludamad
Copy link
Collaborator

ludamad commented Mar 3, 2026

/claudebox iterate on this until CI is working, focus on the 'ci' task

@AztecBot
Copy link
Collaborator Author

AztecBot commented Mar 3, 2026

ClaudeBox: iterate on this until CI is working, focus on the 'ci' task ... workflow run

@AztecBot
Copy link
Collaborator Author

AztecBot commented Mar 3, 2026

Live status · Log

Status: Session completed

Progress

Response: Still running. Let me wait more. | PRs: updated #21073

Pull Requests

@socket-security
Copy link

socket-security bot commented Mar 3, 2026

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatedcargo/​libc@​0.2.180 ⏵ 0.2.1828010093100100
Addedcargo/​env_logger@​0.11.99910093100100

View full report

…20932)

## Summary

Backports two fixes from `next` that enable the AVM transpiler for `linux/arm64` release builds, resolving [#20793](#20793) — `aztec compile` fails with "AVM Transpiler is not enabled" on `linux/arm64`.

**Cherry-picked from:**
- #20814 — added `arm64-linux` cross-compile to `avm-transpiler/bootstrap.sh` + wired `AVM_TRANSPILER_LIB` in `CMakePresets.json`
- #20932 — fixed Makefile dependency (`bb-cpp-cross-arm64-linux` was depending on `avm-transpiler-native` instead of `avm-transpiler-cross-arm64-linux`), plus `barretenberg-rs` release fix

**Root cause:** The `zig-arm64-linux` CMake preset was missing `AVM_TRANSPILER_LIB`, and `avm-transpiler/bootstrap.sh` had no `arm64-linux` case in `build_cross`. The arm64-linux bb binary was compiled without `ENABLE_AVM_TRANSPILER`.

**Changes:**
- `avm-transpiler/bootstrap.sh` — add `arm64-linux` case to `build_cross`
- `barretenberg/cpp/CMakePresets.json` — wire `AVM_TRANSPILER_LIB` for `zig-arm64-linux` preset
- `Makefile` — add `avm-transpiler-cross-arm64-linux` target, fix `bb-cpp-cross-arm64-linux` dependency
- `barretenberg/rust/bootstrap.sh` — add `release` function with on-the-fly binding generation
- `barretenberg/ts/scripts/copy_cross.sh` — relax arch check for release context

**Conflict resolution:** `barretenberg/rust/bootstrap.sh` had a minor conflict — the `release` function didn't exist on v4. Resolved by accepting the full function.

## Test plan
- [x] Native avm-transpiler build succeeds
- [x] Makefile targets verified: `avm-transpiler-cross-arm64-linux`, `bb-cpp-cross-arm64-linux` dependency corrected
- [x] CMake preset verified: `zig-arm64-linux` has `AVM_TRANSPILER_LIB` pointing to correct cross-compiled path
- [ ] Full cross-compilation validated in release CI

Closes #20793

ClaudeBox log: http://ci.aztec-labs.com/596d4a62f30fd2f0-2
@AztecBot AztecBot force-pushed the claudebox/596d4a62f30fd2f0-2 branch from 71753ae to 67b4c9c Compare March 4, 2026 00:30
@ludamad ludamad force-pushed the backport-to-v4-staging branch from 4ff264b to 2d467c9 Compare March 12, 2026 22:29
@ludamad
Copy link
Collaborator

ludamad commented Mar 12, 2026

Cherry-picked directly onto backport-to-v4-staging with conflicts resolved.

@ludamad ludamad closed this Mar 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claudebox Owned by claudebox. it can push to this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants