Copyright © 2016 Ashok P. Nadkarni. All rights reserved.

1. Download and installation

Distributions of the tarray, tarray_ui and xtal packages are available from the SourceForge download area at

1.1. Installing on Windows

Download, and optionally and optionally, from SourceForge. These contain both 32- and 64-bit binaries for Windows. Unpack the distributions into any directory present in the Tcl auto_path variable.

1.2. Installing on other platforms

For other (Unix-like) platforms, the tarray and xtal packages are distributed as TEA-compatible extensions tarray-VERSION.tar.gz and xtal-VERSION.tar.gz. To install an extension, extract into a directory and from the top level directory run the following commands in the shell.

./configure --with-tcl=PATHTOTCLDIR
make install

where PATHTOTCLDIR is the full path to the directory containing the file for the Tcl installation. Note there is no need for a standalone make command since the make install does the actual build as well as install.

The built extensions will support parallelized operations if the libdispatch library is installed on the system. See Enabling parallelized operations for details.

The tarray_ui package, distributed as tarray_ui-VERSION.tar.gz' is a pure Tcl package and can be extracted into any directory that is included in the Tcl `auto_path variable.

2. Building from sources

The tarray and xtal extensions are built using the Critcl package.

  1. Download a copy of the tarray sources by either cloning its Mercurial repository or downloading a snapshot of the sources. See for details.

  2. Download and install the critcl package (3.1 or later) as described in

  3. Set up your compiler environment, for example, running the vcvars.bat file on Windows.

  4. Change to the src directory in the tarray source distribution and run a command of the form

tclsh build.tcl extension ?-target TARGETNAME?
  1. Change to the xtal directory and again run the same command as above to build that extension.

If specified, TARGETNAME should be one of the supported critcl build targets. Naturally, the build environment should reflect the chosen target. If unspecified, it defaults to whatever critcl guesses to be the host platform.

This will create the tarray and xtal packages under the build directory in your source tree.

You can of course create your own build scripts with different Critcl options using the build.tcl file as a template.

3. Enabling parallelized operations

Windows builds have support for parallelized operations using the native Win32 thread API’s. To build parallelized versions for Unix/Linux platforms, the libdispatch library has to be present on the system. If this library is not detected, the extension will not parallelize any operations. This library can be installed using the system’s package manager on most Linux systems.