• Building Tcl on Windows

    From Alan Grunwald@nospam.nurdglaw@gmail.com to comp.lang.tcl on Fri Jul 3 15:56:48 2026
    From Newsgroup: comp.lang.tcl

    [Last one from me for the day!]

    The system disk on my Windows machine failed the other day. I have a new
    one on order but will obviously, have to build and/or re-install a whole
    load of software. From memory, previous attempts to build Tcl have
    failed and I was relying on moderately ancient ActiveTcl installation (8.6.13?). It seems far to retrograde a step to install that on a system
    in 2026, so I shall make another attempt to build the latest Tcl for my Windows system.

    From memory:

    I don't wish to install MagicSplat. It's an excellent package, but,
    quite correctly, it follows recommended Windows installation guidelines
    and I simply can't be bothered to learn these well enough to be able to
    hook up to my extensive library of personalised packages.

    If I install the Visual Studio C++ compiler a) It takes ages to start up
    and b) requires that I put sources etc. etc. in places that I would
    rather not have them.

    Ideally, I'd like to build under Cygwin and install to C:\tcl9.0.4, if I
    must, I'm happy to build under MSys and install to the same place.

    What problems am I likely to come across if I go down this route.
    Nowadays I'm generally a UNIX user so I don't regard searching around
    for sources of packages I might need, and compiling them myself as a "problem".

    Thanks in advance for any help with compile-and-build advice.


    Alan
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From Ralf Fassel@ralfixx@gmx.de to comp.lang.tcl on Fri Jul 3 18:39:50 2026
    From Newsgroup: comp.lang.tcl

    * Alan Grunwald <nospam.nurdglaw@gmail.com>
    | If I install the Visual Studio C++ compiler a) It takes ages to start
    | up and b) requires that I put sources etc. etc. in places that I would
    | rather not have them.

    I think there is a rather current makefile.vc in current TCL source
    releases which should work from a VS cmd.exe.

    | Ideally, I'd like to build under Cygwin and install to C:\tcl9.0.4, if
    | I must, I'm happy to build under MSys and install to the same place.

    We're building TCL/Tk in 'old' msys-1 bash and using the VS compiler:

    - start a VS development cmd.exe to get the necessary environment
    - in that, start msys bash
    - in that:
    export CC=cl PATH=/c/windows/system32:$(PATH)
    cd $(TCLDIR)/win \
    && ./configure --enable-threads --disable-symbols --prefix .... --enable-64bit \
    && make RC=rc STLIB_LD="link.exe -lib -nologo" SHLIB_LD="link.exe -dll -incremental:no -nologo \
    && make install install-private-headers

    I would guess mingw on current msys2 should work even better with all defaults...

    HTH
    R'
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From Alan Grunwald@nospam.nurdglaw@gmail.com to comp.lang.tcl on Fri Jul 3 19:00:16 2026
    From Newsgroup: comp.lang.tcl

    On 03/07/2026 17:39, Ralf Fassel wrote:
    * Alan Grunwald <nospam.nurdglaw@gmail.com>
    | If I install the Visual Studio C++ compiler a) It takes ages to start
    | up and b) requires that I put sources etc. etc. in places that I would
    | rather not have them.

    I think there is a rather current makefile.vc in current TCL source
    releases which should work from a VS cmd.exe.

    | Ideally, I'd like to build under Cygwin and install to C:\tcl9.0.4, if
    | I must, I'm happy to build under MSys and install to the same place.

    We're building TCL/Tk in 'old' msys-1 bash and using the VS compiler:

    - start a VS development cmd.exe to get the necessary environment
    - in that, start msys bash
    - in that:
    export CC=cl PATH=/c/windows/system32:$(PATH)
    cd $(TCLDIR)/win \
    && ./configure --enable-threads --disable-symbols --prefix .... --enable-64bit \
    && make RC=rc STLIB_LD="link.exe -lib -nologo" SHLIB_LD="link.exe -dll -incremental:no -nologo \
    && make install install-private-headers

    I would guess mingw on current msys2 should work even better with all defaults...

    HTH
    R'
    Thanks Ralf, I'll bear that in mind as an option.


    Alan
    --- Synchronet 3.22a-Linux NewsLink 1.2