diff options
| author | Charles Oliver Nutter <headius@headius.com> | 2024-01-18 19:45:05 -0600 |
|---|---|---|
| committer | git <svn-admin@ruby-lang.org> | 2024-01-22 00:12:45 +0000 |
| commit | c6b548accbd211b69b0611b584e7673147aaea41 (patch) | |
| tree | 29082554a4e3375f52edf8e52e533446d7b23eac /lib | |
| parent | e2e15ddd676f4ec69589599bad0961c435c5aba5 (diff) | |
[ruby/nkf] Add JRuby extension to the gem
This pulls in the nkf extension implementation from JRuby. The
build and load logic has been updated along the same lines as
ruby/digest and the gem appears to build correctly for the -java
platform.
Fixes https://github.com/ruby/nkf/pull/13
https://github.com/ruby/nkf/commit/18f57f36ed
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/nkf.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/nkf.rb b/lib/nkf.rb new file mode 100644 index 0000000000..d71717d8d8 --- /dev/null +++ b/lib/nkf.rb @@ -0,0 +1,6 @@ +if RUBY_ENGINE == "jruby" + require 'nkf.jar' + JRuby::Util.load_ext('org.jruby.ext.nkf.NKFLibrary') +else + require 'nkf.so' +end |
