
I. Building the Tcl thread extension for Unix
=============================================

Extension can be compiled on several Unix derivates including various
distributions of Linux. Build process is pretty straightforward. I've
checked some versions of Solaris, Linux and Darwin, but the extension
should compile without problems on any Unix-like operating system
with a proper pthreads library implementation.

To build on Unix-like operating systems, run the CONFIG script:

    % sh CONFIG

That will create a Makefile which you use to run "make" and "make install".
You can use "make clean" to clean the directory from temporary compilation
files and/or "make distclean" to additionaly remove local config files.

You might want to do "make test" before doing the "make install" in order
to run the regression tests on the package. 

To explore other building options, look into the CONFIG file for more
information.


Note for AOLserver users
------------------------

The extension can be compiled as a loadable module for the AOLserver 
version 3.5 or higher. In order to do this, use "--with-aolserver"
configure option to specify the directory containing the AOLserver
distribution. The CONFIG script has an example how to invoke configure
in order to build the extension as AOLserver module.
Note, however, that "make install" and "make test" targets are still
not supported for AOLserver builds. This will be corrected in one of
the future releases.

To fine-tune, you might also want to make the tsv::* commands replace
the AOLserver built-in nsv_* family of commands, since they are API 
compatible and provide richer command set plus advanced shared-object
storage of shared data. Go to the generic/threadSvCmd.h file and look
at the beginning of the file for the:

/* #define NSV_COMPAT 1 */

So, uncomment the line, recompile and there you go.

Since AOLserver, the 3.x series, does not support namespaced
Tcl commands properly, there is a provision at the top of 
generic/tclThread.h file to change the command namespace
to the command prefix. Per default, the "thread::" namespace
is changed to "thread_" prefix and "tpool::" namespace is 
changed to "tpool_" prefix.
For AOLserver 4.x, this is not needed since namespace support
is available.


II. Building optional support libraries
=======================================

As of 2.6 release, this extension supports persistent shared variables.
To use this functionality, you might need to download and compile some 
other supporting libraries. Currently, there is a simple implementation
of shared variable persistency built atop of popular GNU Gdbm package.
You can obtain the latest version of the Gdbm package from the GNU 
website at: http://www.gnu.org/software/gdbm/gdbm.html.

-EOF-
