Ruby/Tk on Mandrake 8.2?

Hi,

I tried to install Ruby with Ruby/Tk today. The problem is, that the tcltklib has not been built by make. Tcl and Tk are installed and working (I don’t have any problems with Tk in Tcl).
If I try to start a simple Ruby program with Tk instructions I get the following:
/usr/local/lib/ruby/1.6/tk.rb:7_in ‘require’: No such file to load – tcltklib (LoadError)
from /usr/local/lib/1.6/tk.rb:7
from tk.ruby:1:in 'require’
from tk.ruby:1

After I wanted to compile Ruby one more time with Tk I noticed that it does not do anything to build tcltklib (but compiles ext/tk). So I checked (started it myself) the extconf.rb in the ext/tcltklib directory and noticed that it breaks after checking for tk.h (checking for tk.h … no). The interesting thing is that it finds the tcl.h but tk.h and tcl.h are existing and ‘whereis’ finds them without problems:

whereis tk.h
tk: /usr/lib/tk8.3 /usr/include/tk.h …

whereis tcl.h
tcl: /usr/lib/tcl8.3 /usr/include/tcl.h …

I’m using Mandrake 8.2 and also tried the rpm’s , but in the rpm’s it’s not to be included …
Anyone had this problem or/and knows a solution?

Bye
Boris S.

P.S.: Ruby rocks! :wink:

“Boris S.” wrote:

I’m using Mandrake 8.2 and also tried the rpm’s , but in the rpm’s it’s not to be included …
Anyone had this problem or/and knows a solution?

I receive some mails from people that cannot use my app because of the
same problem.
I use mdk 8.0 myself and I don’t want to install 8.2.
I would be glad to have a solution to give to that people
(maybe don’t use mdk ? ;->)

···


/ do you play Go? \

http://jeanfrancois.menon.free.fr/rubygo |
\ /


    \   ^__^
     \  (oo)\_______
        (__)\       )\/\
            >>----w |
            >>     >>

Hi,

I tried to install Ruby with Ruby/Tk today. The problem is, that the
tcltklib has not been built by make. Tcl and Tk are installed and working
(I don’t have any problems with Tk in Tcl). If I try to start a simple Ruby
program with Tk instructions I get the following:
/usr/local/lib/ruby/1.6/tk.rb:7_in ‘require’: No such file to load –
tcltklib (LoadError) from /usr/local/lib/1.6/tk.rb:7
from tk.ruby:1:in ‘require’
from tk.ruby:1

After I wanted to compile Ruby one more time with Tk I noticed that it does
not do anything to build tcltklib (but compiles ext/tk). So I checked
(started it myself) the extconf.rb in the ext/tcltklib directory and
noticed that it breaks after checking for tk.h (checking for tk.h … no).
The interesting thing is that it finds the tcl.h but tk.h and tcl.h are
existing and ‘whereis’ finds them without problems:

Whereis, searches your whole tree, whereas make does not. You are already
part way home. (1) you know that you have to build tcltklib yourself using
the extconf.rb, so done, (2) you know that the necessary tcl/tk files exist,
so done, and (3) you know that extconf.rb is not looking for them where you
have them, so you must either (a) change where extconf.rb is looking or (b)
copy or link them to where it is looking.

It appears that you (Mandrake?) installed Tcl/Tk with --prefix=/usr. Yet,
ruby installs, by default, with --prefix=/usr/local. I compiled both from
tarballs with --prefix=/usr and had no problems. So, you might try
compiling ruby with --prefix=/usr.

I installed ruby according to the instructions in the README file:

./configure --prefix=/usr
make
make install

There are also some ruby-specific install files: install-sh, instruby.rb,
mkconfig.rb, etc. I don’t know what these are for. Someone else will have
to explain these. And if they are useful, then why does the README not
mention them? A well made tarball should also include an INSTALL file.

···

On Thursday 18 July 2002 01:13 pm, Boris S. wrote:

whereis tk.h
tk: /usr/lib/tk8.3 /usr/include/tk.h …

whereis tcl.h
tcl: /usr/lib/tcl8.3 /usr/include/tcl.h …

I’m using Mandrake 8.2 and also tried the rpm’s , but in the rpm’s it’s not
to be included … Anyone had this problem or/and knows a solution?

Bye
Boris S.

P.S.: Ruby rocks! :wink:

(maybe don’t use mdk ? ;->)

i can only once again recommend debian, as i am oft prone to do. i have
tried most flavors and have thus become sold on the virtues of debian.
but if you want a more cutting edge distro over debian’s solid
stability, try gentoo. both of these distros take more administrative
work for configuration, but it’s not really that bad, and is well worth
the extra effort as you learn quite a lot by doing.

~transami

···

On Sat, 2002-07-20 at 01:45, MENON Jean-Francois wrote:

“Boris S.” wrote:

I’m using Mandrake 8.2 and also tried the rpm’s , but in the rpm’s it’s not to be included …
Anyone had this problem or/and knows a solution?

I receive some mails from people that cannot use my app because of the
same problem.
I use mdk 8.0 myself and I don’t want to install 8.2.
I would be glad to have a solution to give to that people
(maybe don’t use mdk ? ;->)


/ do you play Go? \

http://jeanfrancois.menon.free.fr/rubygo |
\ /


    \   ^__^
     \  (oo)\_______
        (__)\       )\/\
            >>----w |
            >>     >>


~transami

(") dobee dobee do…
\v/
^ ^

(maybe don’t use mdk ? ;->)

I used to use Mandrake. Now I use gentoo. Mandrake is easy to install
and everything, and that is nice, but once you install you have to deal
with rpm as your pkg management system which, quite frankly, is poor
compared to ports based systems. I recommend switching to a distribution
that has a pkg system based on ports. The ones I know of off the top of
my head are any of the BSD distros (ie. FreeBSD), Debian, and Gentoo.
I highly recommend Gentoo, but use whatever. Just use something that
is easy to maintain a current system. RPM does not fit the bill.

-Michael

I think that is the first time I have ever seen
“whereis” and “whereas” in the same sentence.

Thank you for that. :slight_smile:

Hal

···

----- Original Message -----
From: “Albert Wagner” alwagner@tcac.net
To: “ruby-talk ML” ruby-talk@ruby-lang.org
Sent: Saturday, July 20, 2002 12:21 PM
Subject: Re: Ruby/Tk on Mandrake 8.2?

Whereis, searches your whole tree, whereas make does not.