Skip to content

Cleanup FFI platform files#6503

Merged
headius merged 4 commits intojruby:masterfrom
headius:cleanup_ffi_platform
Dec 21, 2020
Merged

Cleanup FFI platform files#6503
headius merged 4 commits intojruby:masterfrom
headius:cleanup_ffi_platform

Conversation

@headius
Copy link
Member

@headius headius commented Dec 21, 2020

A number of files under the ffi/platform subdir appear to have lineage back to the original addition of FFI support to JRuby and were used by Rubinius to support their own core and standard library classes that used FFI for implementation. Most of these files are no longer used by JRuby, and none of them are versioned by the FFI gem, so this PR will transplate or eliminate them.

Most files are FFI constant declarations, while the platform.conf files appear to have been used internally by Rubinius. Of these files, only the syslog.rb constant definitions and the fcntl related files under x86-64 solaris appear to be in use in JRuby.

Two platform types.conf files exist that do not appear to be in the FFI gem:

  • an enigmatic i486-gnu platform
  • a powerpc64le-linux platform

Of these two files, only the ppc file appears to be relevant, and should probably be contributed back to the FFI gem.

There are not being generated or versioned by the FFI gem so we
need to manage it ourselves.
These platforms are not part of the FFI gem and only exist in
JRuby stdlib, but since we are attempting to source all non-native
FFI code from the gem they should be moved there.
@headius
Copy link
Member Author

headius commented Dec 21, 2020

@larskanis The commit ee15993 deletes two platform types.conf files that do not exist in the FFI gem. The i486-gnu is probably too weird to bother with, but perhaps the powerpc64le-linux config should be transferred to the gem?

@headius headius merged commit 4533311 into jruby:master Dec 21, 2020
@headius headius deleted the cleanup_ffi_platform branch December 21, 2020 20:18
larskanis added a commit to ffi/ffi that referenced this pull request Dec 23, 2020
This file is moved from JRuby to ffi gem as part of
  jruby/jruby#6503
@larskanis
Copy link

@headius I added the powerpc64le-linux/types.conf to ffi gem in ffi/ffi@cf520d7 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants