Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The fiddle gem is broken on truffleruby and jruby #145

Open
eregon opened this issue Sep 16, 2024 · 0 comments · May be fixed by #146
Open

The fiddle gem is broken on truffleruby and jruby #145

eregon opened this issue Sep 16, 2024 · 0 comments · May be fixed by #146

Comments

@eregon
Copy link
Member

eregon commented Sep 16, 2024

Given https://bugs.ruby-lang.org/issues/20309 fiddle will become a bundled gem in Ruby 3.5+.

As a result people will add fiddle to their Gemfile where they previously wouldn't (and so there was no issue).
Unfortunately this leads to failure for example on ffi/ffi#1119:

  • https://github.com/ffi/ffi/actions/runs/10881406447/job/30190278321?pr=1119 JRuby fails when trying to build the C extension
  • TruffleRuby segfaults, probably because the fiddle C extension does something unexpected, and it's completely untested on TruffleRuby. It seems better to use the TruffleRuby Fiddle backend anyway for performance, as it avoids basically going twice through libffi.

I think the best solution for now is to just use fiddle from stdlib on non-CRuby. That's properly tested and working.
IOW, to not build or use the C extension on non-CRuby, similar to how it was done in ruby/stringio#71 or ruby/strscan#35

@eregon eregon changed the title The gem is broken on truffleruby and jruby The fiddle gem is broken on truffleruby and jruby Sep 16, 2024
@andrykonchin andrykonchin linked a pull request Sep 17, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

1 participant