| Ticket UUID: | 2965133 | |||
| Title: | Directory or list thereof (Was: Garbage in -install_name) | |||
| Type: | Bug | Version: | obsolete: 8.6b1 | |
| Submitter: | lars_h | Created on: | 2010-03-07 18:58:44 | |
| Subsystem: | 83. Mac OS X Build | Assigned To: | dkf | |
| Priority: | 8 | Severity: | ||
| Status: | Closed | Last Modified: | 2026-10-22 17:22:35 | |
| Resolution: | Duplicate | Closed By: | serhiy.storchaka | |
| Closed on: | 2026-09-25 08:11:13 | |||
| Description: |
When I build current Tk HEAD (just cd tk/macosx; make test) on this PPC G4 machine running OS X 10.5.8, I get the somewhat curious error
dyld: Library not loaded: /Library/Frameworks/Tk.framework/Versions/8.6:NONE/Tk
as soon as it's trying to start tktest. That ":NONE" looks rather suspicious, don't you think?
As far as I can tell, the problem is that LIB_RUNTIME_DIR is being set up as a colon-separated list of directories, which is then copied to DYLIB_INSTALL_DIR, which in turn is treated as just one directory. Makefile.in sets it up thus:
DYLIB_INSTALL_DIR= ${LIB_RUNTIME_DIR}
and this variable is only used in configure.in, thus:
TK_SHLIB_LD_EXTRAS="${TK_SHLIB_LD_EXTRAS}"' -install_name "${DYLIB_INSTALL_DIR}"/${TK_LIB_FILE}'
But configure.in also contains commands (probably conditionalised) such as
LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${TCL_EXEC_PREFIX}/lib"
LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${x_libraries}"
that treat LIB_RUNTIME_DIR very much as a list of paths.
There is probably also a secondary bug that NONE is being treated as a path, when it really is some kind of null (=no data), but working out what goes wrong there likely requires some understanding of configurations for other platforms, so I won't form any opinion on that.
FWIW, manually editing the build/tk/*/Makefile to remove the second components from the two definitions of LIB_RUNTIME_DIR (one near the top, one in the tktest target instructions) made the Development test succeed, although the Deployment tktest crashes:
/bin/sh: line 1: 53644 Bus error ./tktest /Users/lars/Projekt/Tcl-projekt/Tcl/tk/unix/../tests/all.tcl -geometry +0+0
make[2]: *** [test-classic] Error 138
make[1]: *** [test-tk] Error 2
make: *** [test-deploy] Error 2
But maybe it's better to leave that be until the makefile issue has been sorted out (I'm happy that I could install the Development variant).
| |||
| User Comments: |
serhiy.storchaka added on 2026-09-25 08:11:13:
The spurious ":NONE" was fixed by [335a62271c]. The remaining problem, lars_h added on 2010-03-24 23:38:13: On second though, it is probably better to leave this bug with DKF and having it be on the subject of clarifying what should be in DYLIB_INSTALL_DIR and LIB_RUNTIME_DIR. I'll file a separate bug on the crash of the Deployment executables. Sorry about the noise. lars_h added on 2010-03-24 06:00:07: OK, now the makefile seems to be fine.
The Development variant goes through the test (with some failures, but I believe that's normal).
The Deployment variant crashes tktest, apparently immediately:
make -C "/Users/lars/Projekt/Tcl-projekt/Tcl/tk/macosx/../../build/tk/Deployment" test INSTALL_ROOT='' INSTALL_TARGETS='install-binaries install-libraries install-private-headers install-demos' VERSION='8.6'
DYLD_FRAMEWORK_PATH="`pwd`:/Users/lars/Projekt/Tcl-projekt/Tcl/build/tcl/Deployment:${DYLD_FRAMEWORK_PATH}"; export DYLD_FRAMEWORK_PATH; TCL_LIBRARY=/Users/lars/Projekt/Tcl-projekt/Tcl/tcl/library; export TCL_LIBRARY; TK_LIBRARY=/Users/lars/Projekt/Tcl-projekt/Tcl/tk/library; export TK_LIBRARY; ./tktest /Users/lars/Projekt/Tcl-projekt/Tcl/tk/unix/../tests/all.tcl -geometry +0+0
/bin/sh: line 1: 6111 Bus error ./tktest /Users/lars/Projekt/Tcl-projekt/Tcl/tk/unix/../tests/all.tcl -geometry +0+0
make[2]: *** [test-classic] Error 138
make[1]: *** [test-tk] Error 2
make: *** [test-deploy] Error 2
Any suggestions/instructions on how I might proceed with debugging?
dkf added on 2010-03-23 18:26:52: I don't know what to reorganize things to, but I can now do 'make shell' successfully so it's less urgent. :-) dkf added on 2010-03-23 18:24:53: Squelched the NONE. das added on 2010-03-09 00:00:14: Thanks, that problem was introduced by Donal's change: 2010-02-19 Donal K. Fellows <[email protected]> * unix/configure.in, unix/Makefile.in: [Bug 2415437]: Corrections to allow installation of Tcl and Tk to different directories, especially when neither is a system standard location. Also [Tcl Bug 2307398]. this needs to be adjusted to not use LIB_RUNTIME_DIR as a list of paths (better to use a new var for this IMO) or alternatively to extract the first element for DYLIB_INSTALL_DIR. | |||
Home
Timeline
Branches
Tags
Forum
Tickets
Download
Wiki