-------------------------------------------------------------------------
get STk-3.0.tar.gz from ftp://cs.nyu.edu/pub/local/fox/stk  or
                    ftp://kaolin.unice.fr/pub.  Install it
after configuring with the following:

(non-linux:)

./configure --prefix=... --exec-prefix=...  --enable-hash --enable-stklos \
            --disable-dynload

(linux:)

./configure --prefix=~/STk_inst --exec-prefix=~/STk_inst/exec \
  --enable-hash --enable-stklos --disable-dynload --disable-elf --disable-dld


You won't need to do all of this enabling and disabling once LINK can use
the release of STk, but it's needed for now.  

After configuring, it's:
make
make install
make install.libs

for use:

set an environment variable STK_LIBRARY to 
    $(prefix)/lib/stk/3.0b2

You should be able to run stk now.  Try:
STk>  (require "Tk-classes")
STk>  (define c (make <canvas>))
STk>  (pack c)
STk>  (bye)
-------------------------------------------------------------------------

*****************************************************************************
NOTE:  if you run g++ 2.6.3, you must ensure that it includes the following
patch:  ftp.cygnus.com:pub/g++/gcc-2.6.3-template-fix
.  Otherwise, you will see "multiply defined" errors at link time. 
*****************************************************************************

LINK's Makefile is created by the "configure" script in this directory.
The configuration process uses the file "Makefile.in" as input, so any
changes necessary to the Makefile should be placed in Makefile.in,
then the configuration script should be run again.

At the moment, there is no "install" target;  the executable is placed
in the $LINKBASE/src subdirectory (Define this directory to be $LINKBASE).
LINK is run.

In most cases, the only responsibilities of the user during compilation 
should be to modify the ***Config.mk*** file to tell the configuration script
where to find the tcl and tclX distributions.  But this will not be 
necessary if they are publicly installed.   See the examples Config.mk.*.

The installation process: 

1. set environment variables:
-----------------------------

LINK_BASE 	: <this directory>
LINK_LIBRARY 	: $(STK_PREFIX)/lib/LINK/1.2/  (STK_PREFIX is defined below)
STK_LOAD_PATH 	: <this_directory>/stklos
STK_LIBRARY 	: $(STK_PREFIX)/lib/stk/3.0b2/

2. edit Config.mk
-----------------

	OP_SYS:		the string used by STk to describe the operating
			system.  Go to the directory $STK_LIBRARY and list
			the files.  One should denote an operating system;
			use the string verbatim.

	STK_VERSION:	3.0b2   is the only version of STk for this version 
			of LINK

	LINK_PREFIX:	This is the root directory of the LINK installation
			tree  (the directory you are in now!).

	STK_PREFIX:	This is the root directory in which the STk binaries
			and libraries are installed.  If STk is installed in
			the standard way, this is /usr/local.  The LINK 
			binary and libraries will be installed under this 
			directory

	TK_STK_LIB:	The path to STk's libtk.a  (note: this is *not* Tcl/TK's
			libtk.a;  see the STk distribution)

	TCL_STK_LIB:	The path to STk's libtcl.a  (note: this is *not* Tcl's
			libtcl.a;  see the STk distribution)

	MP_LIB:		The path to STk's libgmp.a


	MP_STK_INCLUDE:	The path to STk's copy of gmp.h

	TK_STK_INCLUDE:	The path to STk's copy of tk.h
	TCL_STK_INCLUDE:The path to STk's copy of tcl.h
	
	FLEX_LIB:	The path to libfl.a

3. compile the system
---------------------

cd $LINK_BASE
./configure
make 
make install	# puts "Link" executable in /usr/local/lib/LINK/1.2/$(OP_SYS), 
		  LINK's libraries in /usr/local/lib/LINK/1.2/, and LINK's
		  include files in /usr/local/lib/LINK/1.2/include; creates
		  a symbolic link called "Link" pointing to the executable.

cstring problem:
if you see this:
----------------------
rom STkTemplateFiles.cc:2:
                                                                               /usr/local/lib/g++-include/std/cstring.h:33: declaration of C function `char * strchr(char *, int)' conflicts with
                                                                               /usr/local/lib/g++-include/std/cstring.h:30: previous declaration `const char * strchr(const char *, int)' here
----------------------
it's an stk.h problem.  Move the includes out from within the extern C
environment in stk.h (this hack until the stk distribution is fixed).


Running LINK:

Link

---------------------------------------------------------------
compiling standalone applications using LINK libraries:

cd standalone
make -f Make.standalone demoNoGUI

(read READ.standalone, then:)  make STK_GUI="yes" -f Make.standalone demo
---------------------------------------------------------------

Please don't hesitate to report problems to Jonathan Berry, the
project leader at:

berryj@numen.elon.edu

NOTE: If you want to look around in the code, see the $LINK_BASE/bin
      directory.  The lvi and rgrep commands are especially useful.
