From: Mansour M. <man...@gm...> - 2021-04-12 18:15:00
|
On Mon, Apr 12, 2021 at 1:29 PM Kevan Hashemi <ha...@br...> wrote: > kevan@KSH5 Tcl % install_name_tool -id \ > @executable_path/../Frameworks/Tcl.framework/Versions/8.6/Tcl Tcl > /Library/Developer/CommandLineTools/usr/bin/install_name_tool: fatal error: the __LINKEDIT segment > does not cover the end of the file (can't be processed) in: Tcl The binary might be corrupted, I think you should rebuild it. > Load command 13 > cmd LC_LOAD_DYLIB > cmdsize 88 > name @executable_path/../Frameworks/Tcl.framework/Versions/8.7/Tcl (offset 24) > time stamp 2 Wed Dec 31 19:00:02 1969 > current version 8.7.0 > compatibility version 8.7.0 > > When my X.dylib is called, it demands that Wish find the following library, regardless of the LC_LOAD_DYLIB fields present in the Wish executable. > > /Library/Frameworks/Tcl.framework/Versions/8.7/Tcl You might want to use run-time search paths (rpaths), like so: $ install_name_tool -change "@executable_path/../Frameworks/Tcl.framework/Versions/8.7/Tcl" "@rpath/../Frameworks/Tcl.framework/Versions/8.7/Tcl" /path/to/X.dylib $ install_name_tool -change "/Library/Frameworks/Tcl.framework/Versions/8.7/Tcl" "@rpath/../Frameworks/Tcl.framework/Versions/8.7/Tcl" /path/to/X.dylib $ install_name_tool -add_rpath "@loader_path" /path/to/X.dylib You might need to do this to both X.dylib and your executable. |