Overview
Artifact ID: | 437d5d47664539497a827310263ad691e85f6ca829eb0cf77ad97edf55220b70 |
---|---|
Ticket: | 1562e10c58f83f0faf2b35feb356c7ec1a0c6300
Installing Tcl on macOS makes other versions of tclsh unable to find Tk. |
User & Date: | marc_culler 2024-08-12 20:50:09 |
Changes
- icomment:
The change which I committed allows tclsh to find the pkgIndex.tcl files for all installed versions of Tk. But it does not work to allow all versions of tclsh to load Tk. It was working fine for me, but I forgot that I was testing with a modified tcl.h file. With the current tcl.h file for Tcl 9.0, you get this: % tclsh9.0 % package require Tk interpreter uses an incompatible stubs mechanism That error is being generated by Tcl_Init_Stubs and causes the package require command to fail, without loading Tk, because Tcl_Init_Stubs has been modified in tcl.h to force an exact version match for Tk 9.0b3. The failure occurs when tclsh9.0 reads the pkgIndex.tcl file for Tk 8.6. I don't understand why this exact match is being required. But whatever the reason, it should still be possible for tclsh9.0 to execute a pkgIndex.tcl script for an incompatible version of Tk without failing when a compatible version of Tk is, in fact, available. If one version of Tk is incompatible it should move on to the next one and not fail until it has checked that all versions are incompatible. I think this is a bug. But a different bug. The fact that it might go away when there is a final release of Tcl / Tk 9.0 does not mean that it is correct.
- login: "marc_culler"
- mimetype: "text/plain"
- username: "Marc Culler"