Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [glimmer-dev] Glimmer Error

Hi Phil,

Have you tried running the example from the command line instead of through Aptana?

You said you are running Linux, so you wouldn't edit JRuby.bat (which is for Windows) but you would edit the jruby shell script in the bin folder.
I think the most important thing to set is the classpath in the jruby shell script so that it knows about the eclipse swt plugins.

-Patrick

-----Original Message-----
From: Phil Crowder [mailto:philcrowder@xxxxxxxxxxxxxx] 
Sent: Tuesday, January 06, 2009 1:55 PM
To: glimmer-dev@xxxxxxxxxxx
Subject: [glimmer-dev] Glimmer Error

Hello.  I'm trying to run the HelloWorld Grimmer example and get the 
following error.

/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/site_ruby/1.8/builtin/javasupport/core_ext/module.rb:19:in 
*`const_missing': cannot link Java class org.eclipse.swt.widgets.Text, 
probable missing dependency: no swt-pi-gtk-3236 in java.library.path 
(NameError)*
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers/data_binding_command_handler.rb:16
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers/data_binding_command_handler.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers.rb:10
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/swt.rb:9
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/swt.rb:5:in 
`require'
    from /home/phil/workspace/Glimmer Test/hello_world.rb:5

It looks like the script is running before the libraries are loaded.  
See the verbose output below.

[Loaded org.jruby.compiler.ASTCompiler$19 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.compiler.ASTCompiler$20 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded 
ruby.jit.ruby.home.phil.aptana.plugins.org_dot_jruby_1_dot_1_dot_6_dot_8388p1.lib.ruby.site_ruby.$1_dot_8.builtin.javasupport.java.__block__27055605_25971327 
from org.jruby.util.ClassCache$OneShotClassLoader]
[Loaded 
ruby.jit.ruby.home.phil.aptana.plugins.org_dot_jruby_1_dot_1_dot_6_dot_8388p1.lib.ruby.site_ruby.$1_dot_8.builtin.javasupport.core_ext.kernel.method_added7885469_25971327 
from org.jruby.util.ClassCache$OneShotClassLoader]
*/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/site_ruby/1.8/builtin/javasupport/core_ext/module.rb:19:in 
`const_missing': cannot link Java class org.eclipse.swt.widgets.Text, 
probable missing dependency: no swt-pi-gtk-3236 in java.library.path 
(NameError)
*    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers/data_binding_command_handler.rb:16
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers/data_binding_command_handler.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers.rb:10
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/command_handlers.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in 
`require'
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/swt.rb:9
    from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/ruby/gems/1.8/gems/glimmer-0.1.0.0/src/swt.rb:5:in 
`require'
    from /home/phil/workspace/Glimmer Test/hello_world.rb:5
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$2 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$3 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$4 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$5 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$6 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$7 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded org.jruby.java.proxies.JavaInterfaceTemplate$8 from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded java.util.jar.JarVerifier from shared objects file]
[Loaded sun.security.util.ManifestEntryVerifier from shared objects file]
[Loaded java.security.Provider from shared objects file]
[Loaded sun.security.provider.Sun from shared objects file]
[Loaded java.security.Provider$ServiceKey from shared objects file]
[Loaded java.security.Provider$EngineDescription from shared objects file]
[Loaded sun.security.provider.Sun$1 from shared objects file]
[Loaded java.security.Security from shared objects file]
[Loaded java.security.Security$1 from shared objects file]
[Loaded java.security.SecureRandomSpi from shared objects file]
[Loaded sun.security.provider.NativePRNG from shared objects file]
[Loaded sun.security.provider.NativePRNG$1 from shared objects file]
[Loaded sun.security.provider.NativePRNG$RandomIO from shared objects file]
[Loaded sun.misc.CharacterDecoder from shared objects file]
[Loaded sun.misc.BASE64Decoder from shared objects file]
[Loaded sun.security.util.SignatureFileVerifier from shared objects file]
[Loaded sun.nio.ByteBuffered from shared objects file]
[Loaded java.io.FilePermissionCollection from shared objects file]
[Loaded java.security.BasicPermissionCollection from shared objects file]
*[Loaded org.eclipse.swt.SWT from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.SWTError from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.SWTException from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded sun.reflect.UnsafeQualifiedStaticCharacterFieldAccessorImpl from 
/usr/lib/jvm/java-6-sun-1.6.0.03/jre/lib/rt.jar]
[Loaded org.eclipse.swt.graphics.Drawable from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.widgets.Widget from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.widgets.Control from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.widgets.Scrollable from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.widgets.Text from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded java.util.EventListener from shared objects file]
[Loaded org.eclipse.swt.internal.SWTEventListener from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.widgets.Listener from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.graphics.Device from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Unloading class sun.reflect.GeneratedConstructorAccessor2]
[Loaded org.eclipse.swt.widgets.Display from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.widgets.Composite from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.internal.Platform from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.internal.gtk.OS from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.internal.Lock from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
[Loaded org.eclipse.swt.internal.Library from 
file:/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar]
*[Loaded java.lang.ExceptionInInitializerError from shared objects file]
[Loaded javax.management.JMException from 
/usr/lib/jvm/java-6-sun-1.6.0.03/jre/lib/rt.jar]
[Loaded javax.management.OperationsException from 
/usr/lib/jvm/java-6-sun-1.6.0.03/jre/lib/rt.jar]
[Loaded javax.management.InstanceNotFoundException from 
/usr/lib/jvm/java-6-sun-1.6.0.03/jre/lib/rt.jar]
[Loaded org.jruby.util.IOOutputStream from 
/home/phil/aptana/plugins/org.jruby_1.1.6.8388p1/lib/jruby.jar]
[Loaded java.util.IdentityHashMap$KeySet from shared objects file]
[Loaded java.util.IdentityHashMap$IdentityHashMapIterator from shared 
objects file]
[Loaded java.util.IdentityHashMap$KeyIterator from shared objects file]
[Loaded java.util.LinkedHashMap$KeyIterator from shared objects file]
*
*I'm using Aptana on Ubuntu Linux with JRuby 1.1.6.  I've set the 
java.library.path using -J option for JRuby in Aptana in the Interpreter 
Arguements 
(-J-Djava.library.path=$LD_LIBRARY_PATH:/home/phil/aptana/plugins/;/usr/lib;/usr/lib/jni).  
I only have 2 swt jar files in the Aptana plugins directory; 
org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar and 
org.eclipse.swt_3.2.2.v3236b.jar.

I tried putting the java.library.path value in the JRuby.bat file as 
well without any luck.  Could use some help.

Thank,
Phil
 
_______________________________________________
glimmer-dev mailing list
glimmer-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/glimmer-dev




Back to the top