small medium large xlarge

08 May 2013, 15:18
Owen Murphy (11 posts)

“Preface. Preparing Your Environment” (xix - xx)

$ cd twitalytics
$ git init
$ git add .
$ git commit -m "initial commit"
$ gem install bundler
$ bundle install --without production

The text does not mention that the reader should expect errors at this point, due to the failure of sqlite3 to build with native extensions. The problem is addressed in “Chapter 1. Getting Started with JRuby” (4), when the sqlite3 dependency is replaced with a jdbc-sqlite3 dependency. But this is 8 pages later, leaving the reader unsure at this point whether to continue or try to resolve the errors.

13 May 2013, 12:36
Joe Kutner (86 posts)

Sorry you ran into this. With JRuby 1.6.7 and sqlite3 1.3.5, there shouldn’t be an error. But this may have changed with new versions of JRuby. Or maybe this is a Windows thing?

21 Jun 2013, 18:52
Gerald Sweet (1 post)

I ran into this issue on 6/20/13 in my Ubuntu 12.04 64-bit VMware guest.

At the @bundle install –without production@ step it hung after displaying this message:

@Installing sqlite3 (1.3.5)@

Eventually I realized that it wasn’t progressing, and interrupted it via ^C, whereupon I saw a lengthy error message. The important part of the message appeared to be this:

@C extension support is not enabled. Pass -Xcext.enabled=true to JRuby or set JRUBY_OPTS or modify .jrubyrc to enable@

I did the following to work around this, based on the recommendation in the error message:

@echo cext.enabled=true > ~/.jrubyrc@ @bundle install –without production@

This allowed the bundle install to complete apparently successfully without further hangs.

At this writing I have not gone any further than that, so your mileage might vary.