Skip to content

Fix: drop magnus "embed" feature (precompiled darwin libruby link)#21

Merged
cpetersen merged 1 commit into
mainfrom
fix/drop-magnus-embed
Jun 20, 2026
Merged

Fix: drop magnus "embed" feature (precompiled darwin libruby link)#21
cpetersen merged 1 commit into
mainfrom
fix/drop-magnus-embed

Conversation

@cpetersen

Copy link
Copy Markdown
Member

The embed feature on the magnus dependency expands to rb-sys/link-ruby, which makes rb-sys link the build machine's shared libruby by ABSOLUTE path instead of using the default -undefined dynamic_lookup. On the CI runner (ruby/setup-ruby, --enable-shared) that baked /Users/runner/hostedtoolcache/Ruby/<v>/arm64/lib/libruby.X.dylib into the precompiled arm64-darwin bundle, so it failed to load on any other Mac (confirmed via otool -L). embed is only for embedding Ruby in a standalone Rust binary, never for an extension cdylib. Dropping it restores dynamic_lookup so Ruby symbols resolve from the host process at load time. Validated against tokenkit (no embed -> portable). Released first as a prerelease for smoke-testing on Mac + Linux.

@cpetersen cpetersen merged commit 0986986 into main Jun 20, 2026
@cpetersen cpetersen deleted the fix/drop-magnus-embed branch June 20, 2026 03:55
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.

1 participant