Skip to content

JRuby Gemfile: C Extension #10

@emnl

Description

@emnl

Great project!

I am having trouble installing ruby-spark via bundle and JRuby. This is what happens:

=> bundle install
Fetching gem metadata from https://rubygems.org/........
Fetching version metadata from https://rubygems.org/..
Resolving dependencies......
Using coderay 1.1.0
Using highline 1.7.2
Using commander 4.3.4
Using diff-lcs 1.2.5
Using distribution 0.7.3
Using ffi 1.9.10
Using tins 0.13.2
Using file-tail 1.0.12
Using method_source 0.8.2
Using nio4r 1.1.0
Using slop 3.6.0
Using spoon 0.0.4
Using pry 0.10.1
Installing rjb 1.5.3 with native extensions

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    /Users/emanuel/.rvm/rubies/jruby-1.7.20.1/bin/jruby -r ./siteconf20150702-1012-k7ach.rb extconf.rb
NotImplementedError: C extension support is not enabled. Pass -Xcext.enabled=true to JRuby or set JRUBY_OPTS.

   (root) at /Users/emanuel/.rvm/rubies/jruby-1.7.20.1/lib/ruby/shared/mkmf.rb:8
  require at org/jruby/RubyKernel.java:1072
   (root) at /Users/emanuel/.rvm/rubies/jruby-1.7.20.1/lib/ruby/shared/rubygems/core_ext/kernel_require.rb:1
   (root) at extconf.rb:6

extconf failed, uncaught signal 1

Gem files will remain installed in /Users/emanuel/.rvm/gems/jruby-1.7.20.1@testing/gems/rjb-1.5.3 for inspection.
Results logged to /Users/emanuel/.rvm/gems/jruby-1.7.20.1@testing/extensions/universal-java-1.8/1.9/rjb-1.5.3/gem_make.out
An error occurred while installing rjb (1.5.3), and Bundler cannot continue.
Make sure that `gem install rjb -v '1.5.3'` succeeds before bundling.

=> ruby -v
jruby 1.7.20.1 (1.9.3p551) 2015-06-10 d7c8c27 on Java HotSpot(TM) 64-Bit Server VM 1.8.0_11-b12 +jit [darwin-x86_64]

=> java -version
java version "1.8.0_11"
Java(TM) SE Runtime Environment (build 1.8.0_11-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.11-b03, mixed mode)

=> cat .rvmrc
rvm --create use jruby-1.7.20.1@testing

The bundle worked when I removed the following lines from ruby-spark's Gemfile:

platform :mri do
  gem 'rjb'
  gem 'msgpack'
  gem 'oj'
  gem 'narray'
end

Strange, of course, as I am not even using MRI.

Any ideas?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions