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

-Xnative.enabled=false fails to load windows in kernel #4349

Closed
enebo opened this issue Dec 1, 2016 · 0 comments
Closed

-Xnative.enabled=false fails to load windows in kernel #4349

enebo opened this issue Dec 1, 2016 · 0 comments
Labels
Milestone

Comments

@enebo
Copy link
Member

enebo commented Dec 1, 2016

We have some hard dep in windows on FFI::Platform when loading kernel. This does not happen for me on MacOS.

jruby -Xnative.enabled=false -e 1
@enebo enebo added the windows label Dec 1, 2016
@enebo enebo added this to the JRuby 9.1.7.0 milestone Dec 1, 2016
@enebo enebo closed this as completed in e3556a4 Dec 15, 2016
headius added a commit to headius/jruby that referenced this issue Jul 26, 2021
In jruby#4349 we saw that this logic does not load properly when native
function calls have been disabled, due to FFI partially loading
and defining an FFI module that was not fully functional. This
is why the previous code here checked for the existence of
FFI::Config rather than just FFI.

However this is still error-prone, so I am restructuring this
logic to do all FFI juggling within the same rescue block as the
require of 'ffi'. If that require raises LoadError or if the
required functions are not present, it immediately falls back on
defining the NotImplemented version of File.symlink.

The same change has been done to the Solaris File#flock logic
below.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant