[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

rb-gnome and gtkglext

anne001

7/23/2006 11:28:00 PM

I ran the darwinports install instructions on rb-gnome
http://rb-gnome.darwin...
I would like to run an example which uses gtkglext:
http://www.bigbold.com/snippets/posts...

I got an error: /opt/local/lib/ruby/vendor_ruby/1.8/gtk2.rb:5:in
`require': no such file to load
-- gdk_pixbuf2 (LoadError)
from /opt/local/lib/ruby/vendor_ruby/1.8/gtk2.rb:5
from /opt/local/lib/ruby/vendor_ruby/1.8/gtkglext.rb:1

what does rb-gnome do? It looked like it installed a bunch of files. Is
it not enough by itself? -- obviously not, I can't find anything with
pixbuf2 on my computer. How do I figure out what is missing and where
to get it for mac OX 10.4?

thanks for your help

15 Answers

Kouhei Sutou

7/24/2006 11:44:00 AM

0

anne001

7/24/2006 3:35:00 PM

0

Thanks for the link. what is it I should install?
If I try to install gettext:

sudo port install gettext
---> Unpacking tgz archive for gettext 0.14.5_0
---> Installing gettext 0.14.5_0
Error: Target com.apple.install returned: Registry error: gettext
0.14.5_0 already registered as installed. Please uninstall it first.
Error: /private/opt/local/bin/port: Status 1 encountered during
processing.

I believe gettext is installed as part of gnome, but for some reason,
gdk-pixbuf-0.22.0 is not,
and I can't install that one. Right now, it does not find glib, even
though glib.h or glib folder even though they are on /private/opt path
/private/opt/local/include/glib-2.0/glib
$PATH
-bash:
/private/opt/local/bin:/private/opt/local/lib:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/mysql/bin/:
No such file or directory

anne001

7/25/2006 12:14:00 AM

0

apparently, one of the problem was that what I needed was rb-gnome2
//sourceforge.net/project/showfiles.php?group_id=53614

I downloaded gnome2 all and gtk2 installed both. But I still got error
messages suggesting
problems with the installation, so I went into ruby-gtk2-0.15.0 and
hand installed gdkpixbuf, glib, gtk (and atk for good measure).

Now I get a new error,
/opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13:in `init': cannot open
display: (null) (RuntimeError)
from /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13
from /opt/local/lib/ruby/vendor_ruby/1.8/gtkglext.rb:1
from openglgtk.rb:2

http://www.ratiatum.com/forum/index.php?showtopic=22038&m...
seem to suggest it might have to do with root privilege and opening an
X11 window
can't do it as a user or some such. Can anyone explain what I need to
do?
the suggestions seem to work for linux and I am on tiger.

anne001

7/25/2006 12:57:00 AM

0

running
export DISPLAY=localhost:0.0
in xterm before running the program does not help. Any other ideas?

anne001

7/25/2006 11:14:00 AM

0

After two days of installs, gnome then gnome2, I don't have gtk, and
gtk2 does not work. And that is with darwinport.
I sure need some pointers.

irb(main):001:0> require "gtk2"
RuntimeError: cannot open display: (null)
from /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13:in `init'
from /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13
from (irb):1

irb(main):002:0> require "gtk"
LoadError: no such file to load -- gtk
from (irb):2:in `require'
from (irb):2

Masao Mutoh

7/25/2006 3:50:00 PM

0

Hi,

Can you execute other X application such as xterm ?

If not, it's not a problem of Ruby-GNOME2.
I recommand to find how to run X application on MacOS X first.

I suspect you don't run X server or don't set xhost,
# I've not try it on MacOS X, though.


On Tue, 25 Jul 2006 09:15:11 +0900
"anne001" <anne@wjh.harvard.edu> wrote:

> apparently, one of the problem was that what I needed was rb-gnome2
> //sourceforge.net/project/showfiles.php?group_id=53614
>
> I downloaded gnome2 all and gtk2 installed both. But I still got error
> messages suggesting
> problems with the installation, so I went into ruby-gtk2-0.15.0 and
> hand installed gdkpixbuf, glib, gtk (and atk for good measure).
>
> Now I get a new error,
> /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13:in `init': cannot open
> display: (null) (RuntimeError)
> from /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13
> from /opt/local/lib/ruby/vendor_ruby/1.8/gtkglext.rb:1
> from openglgtk.rb:2
>
> http://www.ratiatum.com/forum/index.php?showtopic=22038&m...
> seem to suggest it might have to do with root privilege and opening an
> X11 window
> can't do it as a user or some such. Can anyone explain what I need to
> do?
> the suggestions seem to work for linux and I am on tiger.
>
>
>


--
--
:% Masao Mutoh<mutoh@highway.ne.jp>

Daniel Harple

7/25/2006 4:04:00 PM

0

On Jul 25, 2006, at 7:15 AM, anne001 wrote:

> After two days of installs, gnome then gnome2, I don't have gtk, and
> gtk2 does not work. And that is with darwinport.
> I sure need some pointers.
>
> irb(main):001:0> require "gtk2"
> RuntimeError: cannot open display: (null)
> from /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13:in `init'
> from /opt/local/lib/ruby/site_ruby/1.8/gtk2.rb:13
> from (irb):1

Are you running this in an xterm started from /Applications/Utilities/
X11.app?

-- Daniel


anne001

7/25/2006 11:51:00 PM

0

I tried terminal and I tried X11 (xterm) and got the same error in
both. I made sure both
had the same $PATH

anne001

7/26/2006 12:36:00 AM

0

I can run irb, then require "gtk2" in either terminal or xterm (X11)
I got the same answer.

Now I ran xhost localhost
irb(main):001:0> require "gtk2"
=> true
apparently your xhost suggestion was strong medicine, thank you

unfortunately, I am seeing one of the errors which I thought had gone
away:
require "gtkglext"
dyld: NSLinkModule() error
dyld: Symbol not found: _pango_x_font_cache_unload
Referenced from: /opt/local/lib/libgdkglext-x11-1.0.0.dylib
Expected in: flat namespace

something about pango. somebody else seems to have had a problem
http://www.cozmixng.org/~w3ml/index.rb/rabbit-shocke...
don't know what it says.

Kouhei Sutou

7/26/2006 10:22:00 AM

0