From: <apn...@ya...> - 2025-08-07 14:20:58
|
Marc, it worth more than just mentioning 😊 This issue is exactly why I went down this path of testing if zipfs builds really are zipfs builds. Trying to track down why another fix was working on Linux and Windows but not macOS, it turned out it had nothing to do with the fix. It was because the zipfs was not being found at all and it was falling back to the Tcl source library via TCL_LIBRARY in the test suite (which is yet another bug to be fixed – zipfs CI builds should be testing zipfs contained libraries not loading from the source directory). Not pleasant to debug on github CI. Not knowing macos builds, it would be nice if someone who does know the platform disables zipfs for those scenarios. Hint, hint… It would have saved me literally a week’s worth of evenings. /Ashok From: Marc Culler <cul...@gm...> Sent: Thursday, August 7, 2025 7:32 PM To: apn...@ya... Cc: Harald Oehlmann <har...@el...>; apnmbx-public--- via Tcl-Core <tcl...@li...> Subject: Re: [TCLCORE] Adding a "zipfs" tag to the build-info command It may be worth mentioning that embedding the zip file does not work on macOS ARM systems. Adding data at the end of a mach binary corrupts the binary, making it not loadable. The is a hack which works on Intel systems by placing the zip file inside of an arch block in a fat binary. However, on ARM systems every arch in a fat binary must be signed (possibly with an ad-hoc signature) and the signature must go at the end of the block. Adding data at the end of a zip fle corrupts it. So I would recommend always disabling embedding the zip file on macOS. It just causes breakage. It is currently disabled for framework builds but is the default for prefix builds. - Marc On Thu, Aug 7, 2025 at 12:58 AM apnmbx-public--- via Tcl-Core <tcl...@li... <mailto:tcl...@li...> > wrote: Thanks Harald. Also, I see other tags are present that are not mentioned in any TIP so presumably no TIP required for this. As an aside, zipfs is actually a misnomer as zipfs support and command is *always* present. The --disable-zipfs does not remove the functionality, it only disables the embedding of the zip file. I'll also use no-zipfs to be consistent with that. /Ashok -----Original Message----- From: Harald Oehlmann <har...@el... <mailto:har...@el...> > Sent: Thursday, August 7, 2025 12:43 AM To: apn...@ya... <mailto:apn...@ya...> ; apnmbx-public--- via Tcl-Core <tcl...@li... <mailto:tcl...@li...> > Subject: Re: [TCLCORE] Adding a "zipfs" tag to the build-info command As Jan explained to me, the tags are extensable by nature. But I don't see this in TIP599, as it says "may be extended in future". As the "normal" value is no tag, you may add the tag "no-zfs", as "no-threads". Take care, Harald > apnmbx-public--- via Tcl-Core <tcl...@li... <mailto:tcl...@li...> > hat am 06.08.2025 19:35 CEST geschrieben: > > > I would like to add a “zipfs” tag to the {tcl,tk}::build-info command (TIP 599) that would indicate if the {tcl,tk}_library was embedded as a zip file into the binary. Does this require a TIP? I would hope not given that the TIP suggests third-parties could add their own tags. > > The primary use is in the test suite. Based on my manual testing, it is my belief that the Tk test suite actually never tests the embedded zip at all as it sets the TK_LIBRARY environment variable. Further, on macOS I *think* based on github CI logs, even tclsh zipfs builds fail to find the embedded ZIP and instead land up using the init.tcl found by searching up the directory hierarchy. > > The tag would help detect such cases, for example, by checking the value of $tcl_library corresponds to the expected result if the zipfs tag was present. > > (all this is based on my not being aware of any way to check at runtime if the build was configured with –enable-zipfs or –disable-zipfs. If someone can identify a method for this, the tag may not be needed) > > /Ashok > _______________________________________________ Tcl-Core mailing list Tcl...@li... <mailto:Tcl...@li...> https://lists.sourceforge.net/lists/listinfo/tcl-core _______________________________________________ Tcl-Core mailing list Tcl...@li... <mailto:Tcl...@li...> https://lists.sourceforge.net/lists/listinfo/tcl-core |