# Installing Tk

**URL:** <https://www.ruby-forum.com/t/installing-tk/189801>\
**Category:** Ruby\
**Created:** [June 8, 2010, 3:00am UTC](https://www.ruby-forum.com/t/installing-tk/189801 "2010-06-08T03:00:31Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jcubed](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/53a042/32.png) [@jcubed](https://www.ruby-forum.com/u/jcubed)\
**Post date:** [June 8, 2010, 3:00am UTC](https://www.ruby-forum.com/t/installing-tk/189801/1 "2010-06-08T03:00:31Z")

</div>

Hello ruby forums,

Cutting straight to the case,  
I just recently bought a new mac computer, and I am having trouble  
getting ruby to work with Tk.  
I had extraneous trouble getting Tk to work on my old computer, but my  
new one seems to have no version of Tk on it at all. Whereas before I  
had some version of Tk installed (while outdated it still worked very  
well) now I have none, which seems odd as all the tutorials I have  
viewed refer to some version of tk pre-existing!

$ irb

> require ‘tk’  
> LoadError: no such file to load – tk  
> from (irb):1:in `require’  
> from (irb):1  
> from :0

My version of ruby is:  
$ ruby -v  
ruby 1.8.7 (2010-01-10 patchlevel 249) [x86\_64-darwin10]

I am not very good at binding or compiling or making applications on  
terminal, but I do consider myself somewhat good at using the terminal.

I need ruby to work with Tk ASAP!!!  
Any links, solutions, or code, would be very appreciated!

---

<div class="post-metadata">

**Author:** ![jcubed](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/53a042/32.png) [@jcubed](https://www.ruby-forum.com/u/jcubed)\
**Post date:** [June 8, 2010, 10:51am UTC](https://www.ruby-forum.com/t/installing-tk/189801/2 "2010-06-08T10:51:37Z")

</div>

From: Jesse J. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
Subject: Installing Tk  
Date: Tue, 8 Jun 2010 10:00:33 +0900  
Message-ID: [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

> My version of ruby is:  
> $ ruby -v  
> ruby 1.8.7 (2010-01-10 patchlevel 249) [x86\_64-darwin10]

The ruby binary is compiled for x86\_64, but Tcl/Tk frameworks are  
compiled for i386 (not for x86\_64). Maybe, the inconsistency is the  
reason of why no tcltklib is installed.

I think that you need build Tcl/Tk libraries for x86\_64 (probably,  
have to download latest Tcl/Tk sources from CVS to compile on Mac OS X  
10.6) or build ruby binary for i386 with tcltklib.

If you can read Japanese, please read  
[http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-list/46965](http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-list/46965)

I’m not familiar with Mac OS X. So, I’m sorry if I’m wrong.

---

<div class="post-metadata">

**Author:** ![jcubed](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/53a042/32.png) [@jcubed](https://www.ruby-forum.com/u/jcubed)\
**Post date:** [June 8, 2010, 11:36pm UTC](https://www.ruby-forum.com/t/installing-tk/189801/3 "2010-06-08T23:36:14Z")

</div>

Jesse J. wrote:

> That makes some sense… I installed Tcl/Tk through [activestate.com](http://activestate.com)…  
> Does anyone have a specific link to a tutorial for what I need… I  
> don’t want to download a bunch of resource files that I won’t be able to  
> find and delete if they are not the ones I need.

Got it to work using a one click installer that included tk  
[http://rubyosx.rubyforge.org/](http://rubyosx.rubyforge.org/)

---

<div class="post-metadata">

**Author:** ![jcubed](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/53a042/32.png) [@jcubed](https://www.ruby-forum.com/u/jcubed)\
**Post date:** [June 8, 2010, 11:31pm UTC](https://www.ruby-forum.com/t/installing-tk/189801/4 "2010-06-08T23:31:09Z")

</div>

Hidetoshi NAGAI wrote:

> From: Jesse J. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
> Subject: Installing Tk  
> Date: Tue, 8 Jun 2010 10:00:33 +0900  
> Message-ID: [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)
> 
> > My version of ruby is:  
> > $ ruby -v  
> > ruby 1.8.7 (2010-01-10 patchlevel 249) [x86\_64-darwin10]
> 
> The ruby binary is compiled for x86\_64, but Tcl/Tk frameworks are  
> compiled for i386 (not for x86\_64). Maybe, the inconsistency is the  
> reason of why no tcltklib is installed.
> 
> I think that you need build Tcl/Tk libraries for x86\_64 (probably,  
> have to download latest Tcl/Tk sources from CVS to compile on Mac OS X  
> 10.6) or build ruby binary for i386 with tcltklib.
> 
> If you can read Japanese, please read  
> [http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-list/46965](http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-list/46965)
> 
> I’m not familiar with Mac OS X. So, I’m sorry if I’m wrong.

That makes some sense… I installed Tcl/Tk through [activestate.com](http://activestate.com)…  
Does anyone have a specific link to a tutorial for what I need… I  
don’t want to download a bunch of resource files that I won’t be able to  
find and delete if they are not the ones I need.
