bcrypt-ruby / bcrypt-ruby

bcrypt-ruby is a Ruby binding for the OpenBSD bcrypt() password hashing algorithm, allowing you to easily store a secure hash of your users' passwords.
Other
1.93k stars 282 forks source link

bcrypt_ext.jar not build with bundler, but with gem direct #111

Closed erhard closed 9 years ago

erhard commented 9 years ago

I use jruby 1.7.18 on a linux maschine in conjunction with obenjdk . To switch the rubies I use uru. I switched to jruby and installed with bundler so the mri version of bcrypt was installed. When I use gem install bcrypt (I deleted all bryptfiles from the gemDir) then the javaversion was install. So I do not know what is the decisioncriterion of building mri or java version. Perhaps bundler does not work well .

Here my output

erhard@tara:/Daten/work/vertan/processing/vertx$ uru auto                                 
---> Now using jruby 1.7.18 tagged as `1718`
erhard@tara:/Daten/work/vertan/processing/vertx$ rm Gemfile.lock 
erhard@tara:/Daten/work/vertan/processing/vertx$ vim Gemfile
erhard@tara:/Daten/work/vertan/processing/vertx$ bundle install
Fetching gem metadata from https://rubygems.org/....
Resolving dependencies...
/var/lib/gems/1.9.1/gems/bundler-1.7.12/lib/bundler.rb:302: warning: Insecure world writable dir /Daten/work/vertan/processing/vertx in PATH, mode 040777
Installing bcrypt 3.1.10
Using systemu 2.6.4
Using macaddr 1.7.1
Using uuid 2.3.7
Using bundler 1.7.12
Your bundle is complete!
Use `bundle show [gemname]` to see where a bundled gem is installed.
erhard@tara:/Daten/work/vertan/processing/vertx$ o
erhard@tara:~/.gem/jruby/1.7.18/gems/bcrypt-3.1.10/lib$ g v

erhard@tara:/Daten/work/vertan/processing/vertx$ gem install bcrypt
erhard@tara:/Daten/work/vertan/processing/vertx$ 
erhard@tara:/Daten/work/vertan/processing/vertx$ gem install bcrypt
Fetching: bcrypt-3.1.10-java.gem (100%)
Successfully installed bcrypt-3.1.10-java
1 gem installed
erhard@tara:/Daten/work/vertan/processing/vertx$ 
» mc [erhard@tara]:/Daten/work <databases  8:mc*> [[ * master branch ]] »» #vertan 23:06 0
tjschuck commented 9 years ago

Seems like this is an issue either with Bundler or your local setup, not bcrypt-ruby, so going to close this issue.

Have you tried forcing Bundler to use JRuby in your Gemfile? Like:

gem "bcrypt", :platforms => :jruby

If that works, it seems like Bundler is having issues identifying that you're already currently using JRuby (that specification shouldn't be necessary if you're on JRuby currently).

You can also try adding a ruby directive to the top of your Gemfile so it will fail and tell you what version it thinks you're running:

ruby '1.9.3', :engine => 'jruby', :engine_version => '1.7.18'

If that doesn't help, I recommend opening up an issue with Bundler (or if you think it might be related to your local setup particularly, trying somewhere like StackOverflow).