Fixed build on JRuby.