small medium large xlarge

20 Mar 2013, 04:04
Jooin Kim (17 posts)

it says..

   Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
    /Users/nainirajk/.rvm/rubies/jruby-1.7.0/bin/jruby extconf.rb
          NotImplementedError: C extension support is not enabled. Pass -Xcext.enabled=true to JRuby or set JRUBY_OPTS or modify .jrubyrc to enable.
         root) at /Users/nainirajk/.rvm/rubies/jruby-1.7.0/lib/ruby/shared/mkmf.rb:8   require at org/jruby/    (root) at /Users/nainirajk/.rvm/rubies/jruby-1.7.0/lib/ruby/shared/rubygems/custom_require.rb:1    (root) at extconf.rb:2 Gem files will remain installed in /Users/nainirajk/.rvm/gems/jruby-1.7.0@jrubybooks/gems/pg-0.12.2 for inspection. Results logged to /Users/nainirajk/.rvm/gems/jruby-1.7.0@jrubybooks/gems/pg-0.12.2/ext/gem_make.out

what should I do?

20 Mar 2013, 05:08
Jooin Kim (17 posts)

sqllite gem has the same crash..

20 Mar 2013, 06:28
Jooin Kim (17 posts)

this is how I solved

      gem 'sqlite3'


     gem 'activerecord-jdbcsqlite3-adapter', :require => 'jdbc-sqlite3', :require=>'arjdbc'
13 Apr 2013, 00:11
Hendie Dijkman (2 posts)

I followed the advice in the error message and added the line


in the .jrubyrc file in my home folder (it didn’t exist, I had to create it).

14 Apr 2013, 21:15
Bradford Cottel (6 posts)

Yes, I did similar to Hendie… I performed this ~~~ export JRUBY_OPTS=”-Xcext.enabled=true” ~~~ Before I ran my ~~~ bundle install –without production ~~~

Btw, you shouldn’t be getting issues with ‘pg’, but only with ‘sqlite3’, because you are running ‘–without production’ which will exclude the gem ‘pg’ line from being used. In any case if you use the bundle install –without production, you will get an error using sqlite3 which can be solved with either Hendie’s or my solution.

You must be logged in to comment