Вопрос

I am trying to install gems for jruby 1.7.4. I am working with a Java implementation of Ruby that is shipped as part of a program (scripting API). Here is the command I am typing at the command prompt:

java -Xmx500M -jar lib\jruby-complete.jar --command gem install builder --user-install

Here is the error I am running into:

RuntimeCache.java:658:in `<clinit>': java.lang.NoClassDefFoundError: org/jcoding
s/Encoding

    from Ruby.java:216:in `<init>'
    from Ruby.java:275:in `newInstance'
    from Main.java:262:in `internalRun'
    from Main.java:221:in `run'
    from Main.java:201:in `main'

Caused by:

null:-1:in `run': java.lang.ClassNotFoundException: org.jcodings.Encoding

    from null:-1:in `run'
    from null:-2:in `doPrivileged'
    from null:-1:in `findClass'
    from null:-1:in `loadClass'
    from null:-1:in `loadClass'
    from null:-1:in `loadClass'
    from RuntimeCache.java:658:in `<clinit>'
    from Ruby.java:216:in `<init>'
    from Ruby.java:275:in `newInstance'
    from Main.java:262:in `internalRun'
    from Main.java:221:in `run'
    from Main.java:201:in `main'
Это было полезно?

Решение

I resolved my issue. Here is the updated command I used to install the gems: java -Xmx500M -classpath lib\jcodings.jar;lib\joda-time.jar;lib\jruby-complete.jar org.jruby.Main --command gem install GEM --user-install

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top