# Linking to the tk directory

**URL:** <https://www.ruby-forum.com/t/linking-to-the-tk-directory/120241>\
**Category:** Ruby\
**Created:** [November 15, 2007, 3:01am UTC](https://www.ruby-forum.com/t/linking-to-the-tk-directory/120241 "2007-11-15T03:01:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![captaffy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/f04885/32.png) [@captaffy](https://www.ruby-forum.com/u/captaffy)\
**Post date:** [November 15, 2007, 3:01am UTC](https://www.ruby-forum.com/t/linking-to-the-tk-directory/120241/1 "2007-11-15T03:01:00Z")

</div>

I am new to ruby, so I need some help.  
I want to use tk widgets when I teach ruby.  
I have downloaded and installed the ruby-1.8.6-p110  
distribution. When I tried to do the  
“Hello World” window in ruby/tk, irb  
could not find tk. I can find the tk directory  
which is at:

/home/fred/Desktop/ruby/ruby-1.8.6-p110/ext/tk

Is there a shell variable I need to set that  
contains where tk is? I couldn’t find much  
help on google.

Thanks in advance  
john slimick  
removed\_email\_address@domain.invalid

---

<div class="post-metadata">

**Author:** ![captaffy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/f04885/32.png) [@captaffy](https://www.ruby-forum.com/u/captaffy)\
**Post date:** [November 15, 2007, 7:47am UTC](https://www.ruby-forum.com/t/linking-to-the-tk-directory/120241/2 "2007-11-15T07:47:57Z")

</div>

On Nov 14, 2007, at 9:00 PM, John S. wrote:

> I am new to ruby, so I need some help.  
> I want to use tk widgets when I teach ruby.  
> I have downloaded and installed the ruby-1.8.6-p110  
> distribution. When I tried to do the  
> “Hello World” window in ruby/tk, irb  
> could not find tk. I can find the tk directory  
> which is at:
> 
> /home/fred/Desktop/ruby/ruby-1.8.6-p110/ext/tk

That directory only contains the Ruby library that acts as a bridge  
between Ruby and Tcl/Tk.

> Is there a shell variable I need to set that  
> contains where tk is? I couldn’t find much  
> help on google.

Probably not a shell variable problem (although there is a chance it  
is a PATH problem). It is more likely that Tcl/Tk is not installed on  
your system. Perhaps this URL will help.

```
http://ruby.about.com/od/desktop/p/ruby_tk.htm

```

Regards, Morton
