looking for older Tcl/Tk ports

Gustaf Neumann neumann at wu.ac.at
Sun Jun 10 00:08:51 PDT 2012


On 09.06.12 08:32, Jim Graham wrote:
> All failed after attempting to fetch tcl8.4.9-src.tar.gz 
> from http://hivelocity.dl.sourceforge.net/tcl.
...

>  Btw, I'm not sure if I mentioned this in my previous post or not, but I
>  was successful in compiling Tcl 8.4.19 (the last release of 8.4.x), and
>  it works (simple process:  ./configure; make; [as root] make install).
>  The same cannot be said for Tk 8.4.19, sadly.  It builds fine, but when
>  you try to use it, it claims it was not installed properly.

It is not sufficient to replace the tcl8.5 tarball by the 
tcl8.4, one has to make
them live together (without overwriting each other) and on 
has to
configure the ports to use the matching version. I have now 
put together a
few ports requiring tcl 8.4

   - tcl84 (Tcl 8.4.19)
   - tk84 (Tk 8.4.19, using tcl84)
   - tclx (using tcl84)
   - blt (using tk84)

These ports work nicely (tested with 10.7.4 + MacPorts 2.1.1).
The layout is similar to debian:

$ port content tcl84
Port tcl84 contains:
   /opt/local/bin/tclsh8.4
   /opt/local/include/tcl84/tcl.h
   /opt/local/include/tcl84/tclDecls.h
   /opt/local/include/tcl84/tclPlatDecls.h
   /opt/local/lib/libtcl8.4.dylib
   /opt/local/lib/libtclstub8.4.a
   /opt/local/lib/tcl8.4/auto.tcl
   /opt/local/lib/tcl8.4/encoding/ascii.enc
   ...

After the install, The default "tclsh" points still to 
tclsh8.5,
the tclsh of 8.4 has to be invoked with tclsh8.4 (similar 
for "wish").
The port "blt" install its own shell (bltwish), which is 
based on tcl84.

To use tcl84 in a port, one has to point configure
to the right tclConfig.sh and the right includes. For example,
in my blt port, i use:

configure.args        --mandir=${prefix}/share/man \
                         --with-tcl=${prefix}/lib/tcl84 \
                         --with-tk=${prefix}/lib/tcl84 \
                         
--with-tclincls=${prefix}/include/tcl84 \
                         --with-tkincls=${prefix}/include/tcl84

On the way, i have made a backport of Tk bug #2010422
http://sourceforge.net/tracker/index.php?func=detail&aid=2010422&group_id=12997&atid=112997
otherwise, with8.4 spits out an error message, when it starts
on recent version of X11.

On contrary to the blt version for tcl8.5, the version based 
on 8.4
works nicely.

./lang/tcl84/Portfile
./lang/tclx/Portfile
./x11/blt/files/blt-x86_64.patch
./x11/blt/files/patch-configure
./x11/blt/files/patch-demos-Makefile.in
./x11/blt/files/patch-library-Makefile.in
./x11/blt/files/patch-Makefile.in
./x11/blt/files/patch-src-Makefile.in
./x11/blt/files/patch-src-shared-Makefile.in
./x11/blt/Portfile
./x11/tk84/files/genericevent.patch
./x11/tk84/Portfile

In order to contribute these ports, how do you prefer it: should
i open a ticket per port or a single ticket sufficient?

-gustaf neumann


More information about the macports-dev mailing list