[jruby-user] 1.6.0RC1 bson is not picking up the jruby version

1 view
Skip to first unread message

Scott M.

unread,
Jan 30, 2011, 1:56:59 PM1/30/11
to us...@jruby.codehaus.org
I have a rails 3 application that uses mongodb via mongoid. In 1.5.6,
bundle install correctly picks up the jruby version of bson. In
1.6.RC1, it is trying to build bson_ext.

Using bson (1.2.0)
Installing bson_ext (1.2.0) with native extensions
C:/Ruby/jruby-1.6.0.RC1/lib/r
uby/site_ruby/1.8/rubygems/installer.rb:483:in `build_extensions':
ERROR: Failed
to build gem native extension. (Gem::Installer::ExtensionBuildError)

The Gemfile has:
gem 'mongoid', '2.0.0.beta.20'
if defined?(JRUBY_VERSION)
gem 'jruby-openssl'
gem 'bson'
...

Is there some way to force bundler to use the jruby compatible bson
version? I have it installed.

gem list -->
bson (1.2.0 jruby)

Scott M.

--
Posted via http://www.ruby-forum.com/.

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


Matt Fletcher

unread,
Feb 1, 2011, 6:31:24 PM2/1/11
to us...@jruby.codehaus.org
Do you happen to have bson_ext called out somewhere else in the Gemfile? I've been running 1.6.0RC1, Rails 3, and mongoid without any trouble for a couple of weeks.

Here are the relevant gems in my Gemfile:
gem 'rails', '3.0.3'
gem "mongoid", "2.0.0.rc.5"

I don't call out bson or bson_ext. I definitely don't want bson_ext since that's the native extension; bson comes for free since mongoid specifies it as a dependence.

Scott M.

unread,
Feb 2, 2011, 11:13:07 AM2/2/11
to us...@jruby.codehaus.org
Matt,

Thanks for your response. Pulling out the bson line worked. But I
tried putting it back in to cause it to fail again and I couldn't make
bundle install fail (after Gemfile.lock was deleted). I know
switching back and forth (Windows pik) between 1.5.6 and 1.6.0rc1 was
failing - multiple times. I'm sorry I don't have a repeatable bug to
offer.

Thanks for replying.

Reply all
Reply to author
Forward
0 new messages