Version 9 of tcl_pkgPath

Updated 2005-12-15 15:22:54

This variable holds a list of directories indicating where packages are normally installed. See tclvars for more information.

Tcl syntax help


Is this variable obsolete? My 8.4.5 tclsh & wish interps on windows tell me:

 can't read "tcl_pkgPath": no such variable

The teki installer supplied with the winico distribution seems to expect this variable to exist.


The variable was removed from the Windows port of Tcl only, several releases ago. (Bad idea, if you ask me, but they didn't ask at the time).

See Tcl Bug 1072603.

The "teki installer" you have is apparently not up to date.


escargo 22 Aug 2005 - This variable is also missing from the Cygwin port. Any notion of what is being used to find packages instead?

Um, Cygwin is Windows, so we repeat ourselves, there's no tcl_pkgPath variable there.

Even on systems where a tcl_pkgPath variable exists, it is not used to "find pacakges". Rather, its only legitimate use is to direct package installers where (the default package system of) Tcl is looking for packages. If you're not writing a package installer script, just pretend the tcl_pkgPath variable does not exist.

escargo - Cygwin runs on Windows, but it is certainly not an identical environment to Windows.

I think after I ran into this I found more info at auto_path, which does work for finding packages on Cygwin.


Gyus, Cygwin is of course different environment than Windows and Windows is only a base platform for Cygwin. This is only such a thing that there is no Cygwin version of Tcl interpreter and the Windows version (with some slight changes like honoring Cygwin paths) is used instead. That's why the officially distributed tcl package on Cygwin behaves the same as on Windows (try, for example pwd and see the result).

Honestly, I don't know why. I succeeded to compile a native-Cygwin version of tclsh8.5. Maybe there were problems with other packages, like Tk.


Category Dev. Tools | Category Porting