i am trying to compile my jruby script (and hopefully hpricot gem)
with RAWR, however getting the following error. Any ideas here ?
Compliance level ‘1.4’ is incompatible with target level ‘1.5’. A
compliance level ‘1.5’ or better is required
You need to be on Java 1.5 or greater to use JRuby. Rawr by default
targets 1.5, although you can set this to be 1.6 or greater as well.
However, there’s still some quirks here (jrubyc doesn’t take a JVM
target yet, for example, so it’ll always build against whatever JVM
you’re using at the time).
Just FYI: it is possible to set the JVM target version with jrubyc. You
need
to set the java property jruby.bytecode.version.
We do something like this:
java -Djruby.bytecode.version=1.5 -classpath jruby-complete-1.1.4.jar
org.jruby.Main jrubyc.rb
This command is manually retyped here since I’m chunking out the
important
bits from out actual command. The important part is the
-Djruby.bytecode.version piece.