Subject: pkg/30871: can not 'package require Tk' in tclsh
To: None <,,>
From: None <>
List: pkgsrc-bugs
Date: 07/29/2005 22:16:00
>Number:         30871
>Category:       pkg
>Synopsis:       can not 'package require Tk' in tclsh
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jul 29 22:16:00 +0000 2005
>Originator:     Marc Spitzer
>Release:        2.0.1
System: NetBSD 2.0.1 NetBSD 2.0.1 (GENERIC) #1: Mon Jan 24 12:05:44 EST 200
5 i386

In version 8.4 tk was made into a package that could be dynamicly loaded, you should not 
need a seperate wish binary to use tk, all you are suposed to do is "package require Tk"
and you get a gui.  This does not work in the netbsd pkg.   The problem is that 
is not loaded by tclsh, it is by wish:

% package require Tk
couldn't load file "/usr/pkg/lib/tk8.4/../": /usr/pkg/lib/tk8.4/../ Undefined
 PLT symbol "XFreePixmap" (symnum = 23)
nyclogger$ ldd /usr/pkg/bin/tclsh
         -ltcl84.1 => /usr/pkg/lib/
         -lpthread.0 => /usr/lib/
         -lm.0 => /usr/lib/
         -lm.0 => /usr/lib/
         -lc.12 => /usr/lib/
nyclogger$ ldd /usr/pkg/bin/wish 
         -ltk84.1 => /usr/pkg/lib/
         -ltcl84.1 => /usr/pkg/lib/
         -lpthread.0 => /usr/lib/
         -lX11.6 => /usr/X11R6/lib/
         -lm.0 => /usr/lib/
         -lm.0 => /usr/lib/
         -lc.12 => /usr/lib/


package require Tk

add libX11 to the link list, not sure of all the implacations of this though.