Installation of Mongrel gem on JRuby

I bought the Ola Bini‘s eBook on JRuby and started to work through the examples. The installation of the Mongrel gem in JRuby (trunk revision 5341 fails with the following error code:

$ jruby -S gem install -y mongrel
INFO:  `gem install -y` is now default and will be removed
INFO:  use --ignore-dependencies to install only the gems you list
Building native extensions.  This could take a while...
extconf.rb:1:in `require': no such file to load -- mkmf (LoadError)
ERROR:  Error installing mongrel:
	ERROR: Failed to build gem native extension.

This error is logged in JIRA with id JRUBY-1771Workaround (possibly applicable for other gems is to explicitly specify the plaform:

$ jruby -S gem install -y mongrel --platform jruby
INFO:  `gem install -y` is now default and will be removed
INFO:  use --ignore-dependencies to install only the gems you list
Successfully installed mongrel-1.1.2
1 gem installed
Installing ri documentation for mongrel-1.1.2...
Installing RDoc documentation for mongrel-1.1.2...

Advertisements

Comments are closed.

%d bloggers like this: