                        PCN Release 2.0

If you have questions, comments, or bug reports, please send
electronic mail to:

	pcn-support@mcs.anl.gov


Installing PCN
==============

This file describes how to install the PCN on a UNIX based system.
Currently pcn is available on the following machines:

        Workstation Networks:   Sun 4, NeXT, IBM RS/6000, SGI Iris
        Multicomputers:         Intel iPSC/860, Intel Delta
        Shared Memory Machines: Sequent Symmetry

After having untarred pcn_v2.0.tar.Z, you should see the following
files and directories:

BUGS            - outstanding bugs in the release
CHANGES         - changes in this release from previous releases
DISCLAIMER      - PCN disclaimer file
HELP            - a HELP file that will get installed
INSTALL         - directions on how to install PCN (this file)
Makefile        - Makefile for cleaning and tarring PCN system
README          - a description of what is in each installation directory
RELEASE_NOTES	- release notes
configs         - configuration files for various machines
configure	- script for creating a build shadow tree for a particular
			configuration
contrib		- other (contributed) PCN utilities
docs            - PCN documents - latex and postscript forms
examples        - friendly examples of PCN code
man             - PCN man pages
scripts         - some utility shell and perl scripts
src		- source code 
support         - support scripts used by configure
tests           - some test programs.

To install the PCN system, you need to decide where it will reside,
typically we install it in /usr/local/pcn. The sources and
intermediate object files will remain where you have untarred the
distribution file or tape.


Step 1: 
-------

First you must select (and possibly edit) a configuration (we'll call
this <config> from now on).  There are a set of configurations in the
"configs" directory from which you can choose, including:

	delta		- Intel Touchstone Delta
	ipsc860		- Intel iPSC/860
	iris		- SGI Iris
	next040		- NeXT (680x0 CPU)
	rs6000		- IBM RS/6000
	sun4		- Sun 4 (Sparc CPU)
	symmetry	- Sequent Symmetry running Dynix (not PTX)

If none of these supplied configuration files suit your needs, you can
create a new configuration file or edit an existing one.  For more
information of the configuration files, see configs/README file.


Step 2:
-------

Using your favorite editor, modify the <config> file (for example,
'configs/sun4.cf/config') so that:

  * the INSTALL_BASE_DIR to be the directory into which you wish to
install PCN.

  * the other variables in this <config> file are correct

  * if you are installing either the ipsc860 or the delta
configuration, then you also need to edit the PGI variable to make
sure that it points to the directory that contains the Portland Group,
Inc.  compiler.

Please see the file, configs/README, for more information on what each
variable in the configuration file means.

Note 1: You might want to make a backup of the original <config>
before modifying it.

Note 2: If you are installing gauge (i.e., G_BUILD_CONTRIBS contains
"gauge"), you should verify that the X_* variables in the <config>
file are correct.  Because X installations vary widely from site to
site, these variables might need to be changed.


Step 3:
-------

Now that you have the <config> file in the form you wish, you must
create a shadow tree for that configuration.  The build will be done
in this shadow tree.  To create the shadow tree, simply run:

	./configure <config>

This will create a shadow tree of all the PCN source under the
"Build/<config>" directory.


Step 3.5: (symmetry only)
---------

If you are building for the Sequent Symmetry running Dynix (not PTX)
using the symmetry configuration, then you need to make a slight hack
to scripts/pcncomp/pcncomp -- the PCN compiler driver.  You ned to
change the first line from:

#!/bin/sh

to

#!/usr/att/bin/sh

This is because /bin/sh under Dynix is an old version which does not
support functions, whereas /usr/att/bin/sh does, and pcncomp uses
functions.


Step 4:
-------

To build the system for this configuration, go into the
"Build/<config>" directory:

	cd Build/<config>

Then run:

	make build

This could take a while -- anywhere from tens of minutes to hours,
depending on your machine.

symmetry note: The symmetry configuration (and maybe others) requires
gnumake instead of make (check the G_MAKE variable in the
configuration file).  Therefore, you need to run "gnumake build"
instead of the "make build" shown above.


Step 5:
-------

To install the system, first make sure that the INSTALL_BASE_DIR that
you set in step 2 exists and is writable by you.  Then, simply type:

	make install

symmetry note: Again, you may need to use gnumake instead of make.


Step 5.5: (symmetry only)
---------

If you are building for the Sequent Symmetry running Dynix (not PTX)
using the symmetry configuration, then you might want to change the
first line of scripts/pcncomp/pcncomp back to:

#!/bin/sh


PCN Mode for GNU emacs
======================

In the "scripts" directory is the file 'pcn-mode.el'.  This file
contains the GNU emacs lisp code which implements a PCN mode (similar
to the C mode).

For instructions on using this PCN mode, please read the header at the
top of the 'pcn-mode.el', or consult your local emacs guru.

