Prerequisites							     -*-text-*-
~~~~~~~~~~~~~

You need a Haskell 98 compiler.  Currently, this has to be GHC 4.02 upwards or
NHC98 1.0.  To get a Haskell compiler check

  http://haskell.org/


Simple install procedure
~~~~~~~~~~~~~~~~~~~~~~~~

  % gzip -cd <package>.tar.gz | tar xvf -  # unpack the sources
  % cd <package>			   # change to the toplevel directory
  % ./configure				   # run the `configure' script
  % make				   # build everything
  [ Become root if necessary ]
  % make install			   # install all compilers

If there are problems, see the known problems section at the end.  If you are
installing from CVS, please read the corresponding section at the end of this
file first.

The Nitty-Gritty
~~~~~~~~~~~~~~~~

The 'configure' script can be given a number of options to enable
and disable various features. For a complete list, type:

  ./configure --help

A few of the more important ones:

*  --prefix=PREFIX         install architecture-independent files in PREFIX
                           [ Defaults to /usr/local ]

*  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                           [ Defaults to the value given to --prefix ]

*  --enable-prof           enable profiling support

This option is useless in the 4.x series up to, and including, 4.04 of GHC, as
profiling support is broken in these versions.

*  --with-hc=HC            use Haskell compiler HC

This needs to be the full path to the compiler executable.

*  --with-hcflags=HCFLAGS  specify flags for the Haskell compiler

*  --with-ghc-native	   use GHC native code generator (if available)

This option works currently only with GHC 4.07 upwards and only on x86
hardware.

*  --with-efence           link with efence malloc debugger

This option is only meant for debugging.  It reduces the efficiency of the
generated code substantially.


Documentation of the Compiler Toolkit
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
A slightly outdated description of the Compiler Toolkit and the build process
is contained in `doc/base/base.tex'.


Supported Systems and Porting
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Glasgow Haskell Compilation System, Version 4.x; x >= 02

All (compilation) system-dependent code is contained in `base/sysdep/', ie, by
porting the `SysDep' module, other systems should also work.  In case of
problems, contact <chak@cse.unsw.edu.au>.

Restrictions
~~~~~~~~~~~~
The module `base/syntax/Parsers.hs' builds only with GHC 4.x (x >= 06) - if
a version 3.x system is selected, the make process automatically avoids
compiling this module. 

IMPORTANT NOTE: C->Haskell requires the `Parsers.hs' module!

Known Problems
~~~~~~~~~~~~~~
gmake 3.77 (at least on Solaris) - 
  The Makefiles are known not to be working with this version.  Upgrade to a
  later release (eg, 3.78.1 works fine).

Additional Instructions for Building from CVS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you are building from CVS, you have to execute

  % autoreconf

in the toplevel hipar/ directory before continuing with the instructions
above.

