|
From: Marc C. <cul...@gm...> - 2025-10-19 12:52:32
|
Hi Nicolas, Thanks for trying out the installer! Putting Wish.app in the Resources directory and creating symlinks in /usr/local/bin is not some weird thing that I just invented. That is exactly what happens with a standard framework build. In fact, the Tcl and Tk packages which are embedded in the full installer package are created by simply archiving the frameworks built by a standard framework build. It is correct that the installer is fat - it supports intel with an install target of 10.13 and arm with an install target of 11.0. I do not think that /usr/local is an appropriate location for an app bundle. I have never seen that before. It looks like the issues which you are running into when building your app arise from trying to embed signed and notarizes code into your app, poaibly without resigning it. (I can't tell exactly what is involved with your build process.) It also looks like your build process maybe changing dylib load paths, which destroys the signature, without resigning the enclosing framework. That is not really the intended application of the installer. If you are building an app with an embedded Tk you are probably better off building Tk as well and handling the signing and notarization process at the level of your app - signing all executable files, then signing all frameworks, then signing the app, then notarizing the app, then repackaging the notarized app in a new disk image, then notarizing that disk image. The intended use of the installer is for people who just want to run tclsh or wish, possibly with additional extension packages. The package is notarized to make the installation process smoother, without having to remove quarantine xattrs or change system settings. - Marc On Sun, Oct 19, 2025 at 5:26 AM nicolas bats <sl1...@gm...> wrote: > Hi Marc, > I've tried the standard way of the installer. everything is installed > under /Library/Frameworks. > Two alias for tclsh9.1 and wish9.1 are also created in /usr/local/bin > > here's what is inside Tk: > > nico@mac ~ % cd /Library/Frameworks/Tk.framework/Versions/9.1 > > nico@mac 9.1 % ls > > _CodeSignature libtkstub.a PrivateHeaders Tk wish9.1 > > Headers pkgconfig Resources tkConfig.sh > > nico@mac 9.1 % > > > wish9.1 is a fat file: > > nico@mac 9.1 % file wish9.1 > > wish9.1: Mach-O universal binary with 2 architectures: [x86_64:Mach-O > 64-bit executable x86_64] [arm64:Mach-O 64-bit executable arm64] > > wish9.1 (for architecture x86_64): Mach-O 64-bit executable x86_64 > > wish9.1 (for architecture arm64): Mach-O 64-bit executable arm64 > > > and signature works > > nico@mac 9.1 % codesign -dv wish9.1 > > Executable=/Library/Frameworks/Tk.framework/Versions/9.1/wish9.1 > > Identifier=com.tcltk.wish > > Format=Mach-O universal (x86_64 arm64) > > CodeDirectory v=20500 size=506 flags=0x10000(runtime) hashes=5+7 > location=embedded > > Signature size=8972 > > Timestamp=13 Oct 2025 at 17:08:03 > > Info.plist entries=20 > > TeamIdentifier=A3LBEGBB69 > > Runtime Version=26.0.0 > > Sealed Resources=none > > Internal requirements count=1 size=176 > > > but on my computer running macOS26 wish9.1 is identified as a document > file, not as an app that I can run > > so I went to Resources where the is a Wish.app. > > > running this one (double-click on Wish) prints this error: > > invalid command name "ttk::toggleswitch::CondUpdateElements" > while executing > "ttk::toggleswitch::CondUpdateElements" > () 1 % > > > and file/Run Widget demo is not accessible > > > after I've tried to link my app against installed Tcl.framework and > Tk.framework and it fails. > > here's what my script is saying: > > -- fixup_bundle: fixing... > > -- 27/52: fixing up > '/Users/nico/daylight/build/DLight.app/Contents/MacOS/DLight' > > -- 28/52: fixing up > '/Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tcl.framework/Versions/9.1/Tcl' > > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool: > warning: changes being made to the file will invalidate the code signature > in: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tcl.framework/Versions/9.1/Tcl > (for architecture x86_64) > > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool: > warning: changes being made to the file will invalidate the code signature > in: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tcl.framework/Versions/9.1/Tcl > (for architecture arm64) > > -- 29/52: fixing up > '/Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Tk' > > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool: > warning: changes being made to the file will invalidate the code signature > in: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Tk > (for architecture x86_64) > > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool: > warning: changes being made to the file will invalidate the code signature > in: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Tk > (for architecture arm64) > > > then: > > -- executable file 1: > /Users/nico/daylight/build/DLight.app/Contents/MacOS/DLight > > -- executable file 2: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish.app/Contents/MacOS/Wish > Shell > > -- executable file 3: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish.app/Contents/MacOS/Wish > > -- executable file 4: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish > Shell.app/Contents/MacOS/Wish Shell > > -- executable file 5: > /Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish > Shell.app/Contents/MacOS/Wish > > -- verified='0' > > -- info='external prerequisites found: > > f='/Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish.app/Contents/MacOS/Wish > Shell' > > > external_prereqs='/Library/Frameworks/Tcl.framework/Versions/9.1/Tcl;/Library/Frameworks/Tk.framework/Versions/9.1/Tk' > > ;external prerequisites found: > > > f='/Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish.app/Contents/MacOS/Wish' > > > external_prereqs='/Library/Frameworks/Tcl.framework/Versions/9.1/Tcl;/Library/Frameworks/Tk.framework/Versions/9.1/Tk' > > ;external prerequisites found: > > f='/Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish > Shell.app/Contents/MacOS/Wish Shell' > > > external_prereqs='/Library/Frameworks/Tcl.framework/Versions/9.1/Tcl;/Library/Frameworks/Tk.framework/Versions/9.1/Tk' > > ;external prerequisites found: > > f='/Users/nico/daylight/build/DLight.app/Contents/Frameworks/Tk.framework/Versions/9.1/Resources/Wish > Shell.app/Contents/MacOS/Wish' > > > external_prereqs='/Library/Frameworks/Tcl.framework/Versions/9.1/Tcl;/Library/Frameworks/Tk.framework/Versions/9.1/Tk' > > ' > > -- > > CMake Error at > /usr/local/share/cmake-3.31/Modules/BundleUtilities.cmake:1127 (message): > > error: verify_app failed > > Call Stack (most recent call first): > > /usr/local/share/cmake-3.31/Modules/BundleUtilities.cmake:994 > (verify_app) > > cmake_install.cmake:174 (fixup_bundle) > > > so it seems that for me the installer isn't good because of wish / wish > shell presence inside the Framework. > > Can you locate them in /usr/local/bin instead of inside the framework? > > > hope this helps, > > best regards, > > nicolas > > > > > Le dim. 19 oct. 2025 à 04:47, Marc Culler <cul...@gm...> a écrit : > >> I have been working on a binary installer for Tcl, Tk and selected >> extension packages. I would be interested in any feedback that people can >> provide after trying it out. >> >> You can download the signed and notarized Installer package here: >> >> https://github.com/culler/tcltk_pkg/releases/download/v0.0-alpha/tcltk9.1.pkg >> >> - Marc >> _______________________________________________ >> Tcl-Core mailing list >> Tcl...@li... >> https://lists.sourceforge.net/lists/listinfo/tcl-core >> > |