lian / bitcoin-ruby

bitcoin utils and protocol in ruby.
Other
922 stars 322 forks source link

How to get bitcoin-ruby to work with JRuby? #192

Open isho opened 8 years ago

isho commented 8 years ago

Any ideas about what is required to get the bitcoin-ruby gem to work in JRuby?

Does something like this: https://github.com/jruby/jruby-openssl work?

I ported my app over and this is the error I'm getting:

LoadError: RMD160 not supported without BouncyCastle
                                 require at org/jruby/RubyKernel.java:1071
                                 require at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/activesupport-4.1.9/lib/active_support/dependencies.rb:247
                         load_dependency at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/activesupport-4.1.9/lib/active_support/dependencies.rb:232
                                 require at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/activesupport-4.1.9/lib/active_support/dependencies.rb:247
                                  (root) at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/bitcoin-ruby-0.0.7/lib/bitcoin.rb:5
                                 require at org/jruby/RubyKernel.java:1071
                                 require at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/activesupport-4.1.9/lib/active_support/dependencies.rb:247
                         load_dependency at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/activesupport-4.1.9/lib/active_support/dependencies.rb:232
                                 require at /Users/isho/.rbenv/versions/jruby-1.7.19/lib/ruby/gems/shared/gems/activesupport-4.1.9/lib/active_support/dependencies.rb:247
                                  (root) at /Users/isho/_code/plutus-server/config/initializers/bitcoin_network.rb:1
mhanne commented 8 years ago

This is as far as I got with it: https://github.com/jruby/jruby/issues/1261

Didn't know about jruby-openssl, might be worth a try!