Subject: perl/tk

From: Dirk Bernhardt <[email-masked]>
Date: 29 Aug 1996 18:16:17 +0200

-----BEGIN PGP SIGNED MESSAGE-----

Hi!

I have a problem with perl and perl/tk:

==============================================================
bash$ cat tktest.pl
#!/usr/bin/perl -w

use diagnostics;
use strict;
use Tk; 

my $main = new MainWindow;
$main->Label(-text => 'Hello, world!')->pack;
$main->Button(-text => 'Quit',
   -command => sub{exit}
   )->pack;
MainLoop;

bash$ ./tktest.pl
Uncaught exception from user code:
	Can't find loadable object for module Tk in @INC (/usr/lib/perl5/i486-linux/5.003 /usr/lib/perl5 /usr/local/lib/site_perl/i486-linux /usr/local/lib/site_perl .) at /usr/lib/perl5/Tk.pm line 35
	Carp::croak called at /usr/lib/perl5/DynaLoader.pm line 115
	DynaLoader::bootstrap called at /usr/lib/perl5/Tk.pm line 35
	require Tk.pm called at ./tktest.pl line 5
	main::BEGIN called at /usr/lib/perl5/DynaLoader.pm line 0
	eval {...} called at /usr/lib/perl5/DynaLoader.pm line 0
BEGIN failed--compilation aborted at ./tktest.pl line 5.
bash$ 
==============================================================

That's right, since I have the TK subdirectory in

==============================================================
bash$ ls /usr/lib/perl5/i486-linux/5.002/Tk/
Config.pm    pTk	  tkGlue.def   tkGlue.m	    tkGlue_f.h
leak_util.h  reghack.h	  tkGlue.h     tkGlue.t
bash$ 
==============================================================

I've installed both from Debian 1.1.5:

==============================================================
bash$ dpkg -l | grep perl
ii  perl            5.003-2        Larry Wall's Practical Extracting and Report
ii  perl-tk         b11.02-2       This is a perl module providing support for 
bash$ 
==============================================================

What can I do?

Ciao,
        - Krid -

--
cand. ing. Dirk Bernhardt | PGP mail preferred   | .oooO  Oooo.  Set your feet
Tittardsfeld 110          | Key ID 1024/D18B8A75 | (   )  (   )  free and your
52072 Aachen, Germany     | Linux: the choice    |  \ (    ) /   mind will
+49 241 173236            | of a GNU generation  |   \_)  (_/    follow.

---

From: Rob Browning <[email-masked]>
Date: 30 Aug 1996 12:00:31 -0500

Dirk Bernhardt <[email-masked]> writes:

> ii  perl            5.003-2
> ii  perl-tk         b11.02-2

> What can I do?

I'm pretty sure you have incompatible versions of perl and perl-tk.  I
believe that perl-tk b11.02-3 is the first version compatible with
perl 5.003.

You can get this version from

ftp.debian.org:/debian/unstable/binary-i386/devel/perl-tk_b11.02-3.deb

--
Rob