Menu

#2822 Default LIBDIR not on Tk's auto_path

obsolete: 8.6b1.1
open
5
2010-07-12
2010-07-12
No

Having recently bought a new computer, I've had to recompile a number of packages. In doing so, I've noticed that TEA seems default to putting things in /usr/local/lib, which I suppose makes sense. The problem is however that this directory doesn't appear on Wish's auto_path:

% info patchlevel
8.6b1.2
% set auto_path
/Library/Frameworks/Tcl.framework/Versions/8.6/Resources/Scripts /Library/Frameworks/Tcl.framework/Versions/8.6/Resources /usr/local/bin/../../../Library/Frameworks/Tk.framework/Versions/8.6/Resources/Wish.app/Contents/lib ~/Library/Tcl /Library/Tcl /System/Library/Tcl ~/Library/Frameworks /Library/Frameworks /System/Library/Frameworks /Library/Frameworks/Tk.framework/Versions/8.6/Resources/Scripts /Library/Frameworks/Tk.framework/Versions/8.6/Resources/Scripts/ttk
% info nameofexecutable
/usr/local/bin/../../../Library/Frameworks/Tk.framework/Versions/8.6/Resources/Wish.app/Contents/MacOS/Wish

I suppose the problem surfaces for wish but not for tclsh because the actual wish executable isn't locaed in /usr/local/bin, whereas tclsh gets its /usr/local item on auto_path from [info nameofexecutable]; for tclsh the corresponding results are:

% info patchlevel
8.6b1.2
% set auto_path
/Library/Frameworks/Tcl.framework/Versions/8.6/Resources/Scripts /Library/Frameworks/Tcl.framework/Versions/8.6/Resources /usr/local/lib ~/Library/Tcl /Library/Tcl /System/Library/Tcl ~/Library/Frameworks /Library/Frameworks /System/Library/Frameworks
% info nameofexecutable
/usr/local/bin/tclsh8.6

I'm not sure how best to proceed. It would be nice if TEA could rather default to have at least platform-independent files in /Library/Tcl on MacOSX, but perhaps the more pragmatic approach is to ensure Wish is looking in /usr as well.

Discussion