Skip to content

ffi: replace native-decide C shim with Rust dynlib - #534

Merged
arthurpaulino merged 2 commits into
mainfrom
ap/ix-rs-dyn
Aug 4, 2026
Merged

ffi: replace native-decide C shim with Rust dynlib#534
arthurpaulino merged 2 commits into
mainfrom
ap/ix-rs-dyn

Conversation

@arthurpaulino

Copy link
Copy Markdown
Member

No description provided.

@samuelburnham
samuelburnham force-pushed the ap/ix-rs-dyn branch 2 times, most recently from 9ca3984 to d076a18 Compare August 4, 2026 18:43
arthurpaulino and others added 2 commits August 4, 2026 15:54
Replace the `ix-rs-dyn` crate with a Lake target that assembles the
elaboration-time dynlib from artifacts that already exist, so no FFI ABI
is mirrored by hand:

- Boxed entry points come from Lean's generated objects for the declaring
  modules (`Blake3`, `Blake3.Rust`, `Ix.Unsigned`), fetched via each
  module's `oExport` facet — the same code linked into normal executables.
- Raw symbols come from the `blake3_rs` and `ix-ffi` `cdylib` outputs,
  recorded as load-time dependencies by absolute path (no `LD_LIBRARY_PATH`).
  The toolchain's `libgmp.a` is folded in to satisfy `ix-ffi`'s Nat bridge.

This drops the duplicated BLAKE3 backend and its independent `=1.8.4` pin
(restoring blake3 1.8.5 in Cargo.lock), and removes the `ix-rs-dyn` crate.
`ix-ffi` and the pinned Blake3 dependency now build a `cdylib` alongside
their staticlib.
@arthurpaulino
arthurpaulino merged commit 34d43c6 into main Aug 4, 2026
11 checks passed
@arthurpaulino
arthurpaulino deleted the ap/ix-rs-dyn branch August 4, 2026 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants