Thoughts on Tcl (long but necessary)

Bruce Dubbs bruce.dubbs at
Fri Apr 28 17:01:24 PDT 2006

Randy McMurchy wrote:
> Randy McMurchy wrote these words on 04/28/06 17:19 CST:
>> I'm sure I can make a change to the sedding of so that
>> all the headers would be found if they are all in /usr/include. But
>> do the headers that are not installed matter?
> One solution I see is to modify the file so that it only
> looks in /usr/include for headers and then just do a one-line
> command to manually install the headers:
> install -v -m644 *.h ../generic/*.h /usr/include
> Only thing is, how many (broken) applications bypass and
> look in /usr/include/tcl8.4/unix for headers? Sure the app should be
> considered broken, but do we want to find this out this close to
> release?
> Perhaps this whole issue can be pushed off until after the release.
> Anyway my two cents.

The whole thing is a bit confusing.  Let me see if I understand.
Version one is:

cd unix &&
./configure --prefix=/usr --enable-threads &&
make &&
sed -i -e "s:${PWD}/unix:/usr/lib:" \
       -e "s:${PWD}:/usr/include/tcl&tklver;:" \
       -e "/TCL_LIB_FILE/ s:':\":g" \

make install &&
install -v -d /usr/include/tcl&tclver;/unix &&
install -v -m644 *.h /usr/include/tcl&tckver;/unix/ &&
install -v -d /usr/include/tcl&tclver;/generic &&
install -v -c -m644 ../generic/*.h /usr/include/tcl&tclver;/generic/ &&

rm -v -f /usr/include/tcl&tckver;/generic/{tcl,tclDecls,tclPlatDecls}.h &&

ln -v -nsf ../../include/tcl&tclver; /usr/lib/tcl&tclver;/include &&
ln -v -sf libtcl&tclver;.so /usr/lib/ &&
ln -v -sf tclsh&tclver; /usr/bin/tclsh

And version two replaces the area between ===== with:

make install-private-headers
and some other stuff

The other issue is what headers get installed.  As I look at the book, I
see the following packages that mention tcl:

Without going into each package, it would seem that the authors put the
headers they think others need into the Makefile.

For instance, going through graphviz, I see:

tclpkg/tclstubs/tclStubLib.c:#include "tcl.h"
tclpkg/tclhandle/tclhandle.c:#include "tclhandle.h"
tclpkg/gdtclft/gdtclft.c:#include <tcl.h>
tclpkg/gdtclft/gdtclft.c:#include "tclhandle.h"
tclpkg/gv/gv_tcl.cpp:#include <tcl.h>
tclpkg/tclpathplan/tclpathplan.c:#include <tcl.h>
tclpkg/tclpathplan/tclpathplan.c:#include "tclhandle.h"
tclpkg/tcldot/tkgen.c:#include "tcldot.h"
tclpkg/tcldot/tcldot.c:#include "tcldot.h"
tclpkg/tcldot/tcldot.h:#include "tcl.h"
tclpkg/tcldot/tcldot.h:#include "tclhandle.h"

Note that tclhandle.h and tcldot.h are local files.  The only external
header is tcl.h.

I suspect the other packages are the same way. We could try just the
private headers and see if any of the other packages miss the other
headers. We wil be doing a complete rebuild for the 6.2 release anyway.

Right now, my /usr/include has three related files:
tcl.h  tclDecls.h  tclPlatDecls.h

where tcl.h includes the other two.  I would really think those and the
others installed by install-private-headers would handle it.  I suspect
the other headers are for internal tcl use only.

  -- Bruce

More information about the blfs-dev mailing list