Overview
| Artifact ID: | 1a9c7a7eccfbc3cb9c7bb672386afd428eccd2a101a0df65c948971f4e925dbc |
|---|---|
| Ticket: | ad7bafd5e11cfa09e9ed91ae4acff706438705e1
auto_path/tcl_library consistency for zipfs filesystem |
| User & Date: | juliannoble2 on 2024-10-06 19:13:24 |
Changes
- assignee changed to: "nobody"
- closer changed to: "nobody"
- cmimetype changed to: "text/x-fossil-plain"
- comment changed to:
The default location for init.tcl and hence tcl_library that is setup in tclZipfs.c is //zipfs:/app/tcl_library This is not directly an immediate issue - but then init.tcl adds the parent dir to the auto_path. This ends up as //zipfs:/app Aside from //zipfs:/app and //zipfs:/app/tcl_library - there aren't any other //zipfs:/.. entries in the auto_path by default. A user setting up a tclkit-like system then has to store library folders directly in the first usable dir ie somewhere like //zipfs:/app/mypackage1 //zipfs:/app/mypackage2 tclPkgUnknown will scan all base user folders for pkgIndex.tcl files eg things like //zipfs:/app/doc //zipfs:/app/modules which aren't applicable and while fast enough in zipfs - doesn't seem efficient/scalable If the user tries to organise libraries under something like //zipfs:/app/lib - it's only going to work if they adjust the auto_path - or create a //zipfs:/app/lib/pkgIndex.tcl to point to the folders therein. //zipfs:/app is analogous to the normal tcl install folder (on windows at least) containing things like apps,bin,doc,include,lib,licenses,samples etc. The fact that zipfs:/app/tcl_library is at the same level as those (rather than something like //zipfs:/app/lib/tcl9.0) is no big deal in itself - but the default of having to store each library folder at the same level as docs etc (without fiddling things) seems confusing. It also makes the filestructure for //zipfs:/ less compatible/sensible for those trying to bring things across from old tclkits. Creating a wrapped executable as per the instructions in tip 430 works - but the resultant executable now depends on init.tcl etc from the external filesystem, or for the user to add that back in for the exe to be independent. To add that in - the first inclination would be to just bring in the lib folder from the tcl installation dir as a whole - but that won't work as init.tcl still won't be found. The user could then move the lib/tcl9.0 to be tcl_library at the root of the .vfs and it will work - including finding things like lib/tcl9/9.0/platform-1.0.19.tm - but any pkgIndex.tcl based libraries at lib/whatever won't be found as mentioned above. If a tool equivalent to the old sdx gets made for zipfs based executables to easily 'unwrap' and 'wrap' a .vfs folder - the situation could be much improved - but I'm tempted to consider this as a bug in consistency and usability that doesn't seem necessary(?) Before anyone attempts to build a modern SDX equivalent for zipkits and distribute it - can we review this? Any other opinions?
- foundin changed to: "9"
- is_private changed to: "0"
- login: "juliannoble2"
- priority changed to: "5 Medium"
- private_contact changed to: "957fdfcd8744611e3fe1f4896c7538b1d9bf47b2"
- resolution changed to: "None"
- severity changed to: "Important"
- status changed to: "Open"
- submitter changed to: "juliannoble2"
- subsystem changed to: "- New Builtin Commands"
- title changed to:
auto_path/tcl_library consistency for zipfs filesystem
- type changed to: "Bug"