Subject: Re: TCL Version
To: Mahesh Chittur <>
From: Martin S. Weber <>
List: tech-pkg
Date: 06/08/2004 11:44:10
On Tue, Jun 08, 2004 at 09:04:39AM +0000, Mahesh Chittur wrote:
> hi,
> I was trying to build few packages that were depend on tcl.
> My problem is:
> 	I have packages that would run in both tcl 8.3 and  8.4. Before, i 
> 	had tcl 8.3 as default package under pkgsrc/lang/tcl. So, i included the 
> library libtcl83.a. Now its tcl 8.4 under pkgsrc/lang/tcl, so the library 
> name changes to libtcl84.a. when i build the package i get errors.
> Is there a way to get the version of installed tcl other than writing a 
> configure script. 

echo 'puts "Tcl version is [info patchlevel]"
puts "\tlibrary version: [info tclversion]"
puts "\tscript dir(s): [info library]"' | tclsh

echo 'puts "Tcl library name is /usr/pkg/lib/libtcl[regsub {\.} [info tclversion] ""].a"' | tclsh

Of course substitute your tcl-installation prefix instead of /usr/pkg.