These step by step instructions should help you get Unify working.  If
you have any problems, you should send mail to unify@dcs.uky.edu.

1) Install pvm

   For Unify to work, you must have pvm installed.  The pvm home page
   is http://www.epm.ornl.gov/pvm/pvm_home.html.  Install pvm and set
   the environment variables $PVM_ROOT and $PVM_ARCH accordingly.  By
   default, the makefile will install test applications in
   $PVM_ROOT/bin/$PVM_ARCH, so it should be writable and you should
   add it to your path.

   If pvm is installed in a common place on your system, such as
   /usr/local/pvm3, you probably want to install binaries in a local
   directory so that they do not conflict with others.  You can avoid
   installing the complete version of pvm in your home directory if
   you make your own pvm3 and pvm3/bin directories (e.g., "mkdir
   $HOME/pvm3 ; mkdir $HOME/pvm3/bin") and make symbolic links to your
   system's pvm3/lib and pvm3/include directories (e.g., "ln -s
   /usr/local/pvm3/lib /usr/local/pvm3/include $HOME/pvm3").

2) Configure the Makefiles

   Run ./configure in the top level directory to generate the Makefile
   for your system.  Use the --prefix option to indicate where
   library, binary, and header files should be installed.  By default,
   they are installed relative to the top level unify directory.  To
   install in /usr/local just type "./configure --prefix=/usr/local".

   To force Unify to use SEClib for event counters and sequencers, use
   the "--enable-SEClib".  To use segment based event counters and
   sequencers, run configure with the "--disable-SEClib" option.
   SEClib is enabled by default.

   To force Unify to use multicast for certain types of communication,
   the "--enable-MULTICAST".  To use force the use of unicast only,
   run configure with the "--disable-MULTICAST" option.
   Multicast is enabled by default.

3) Set XUNIFY_ROOT

   If you wish to use Xunify, set your XUNIFY_ROOT environment
   variable to point to the directory in which Xunify resides.  For
   example if you have unpacked the unify package into
   $HOME/unify_pkg, type 

        setenv XUNIFY_ROOT $HOME/unify_pkg/tools/xunify

   For Xunify to work properly, XUNIFY_ROOT must be set properly both
   when compiling Xunify and when running Xunify.

4) Compile the Unify library and Xunify

   From the top level directory type "make depend ; make".

5) Install Unify and Xunify

   From the top level directory type "make install".

6) Compile the sample applications

   From the top level directory type "make apps".

7) Install the sample applications

   From the top level directory type "make appinstall".

To run one of the applications without Xunify

1) Type "pvm" to start pvm.

2) Add at least one machine for every worker process you would like to
   have, plus one more (e.g., 4 workers => 5 machines).  For example,

   add machine1
   add machine2
   add machine3
   add machine4
   add machine5

3) Type "quit" (not halt) in pvm to get back to the command line.

4) Run the application.

   To run matmul with 4 workers

        matmul -- -n 4

   If the applications have been installed in a directory in your
   path, you can run them from any directory.  The applications are
   installed in $PVM_ROOT/bin/$PVM_ARCH by default.

   All of the example applications produce output in the directory in
   which they were compiled and your home directory.  In your home
   directory, the application generates one file for each worker
   process, start.p, where p is one less than the worker number of the
   process.  After the program has finished initialization, each
   worker writes a file into the directory in which the program was
   compiled named output.n.p, where n is the number of workers and p
   is one less than the worker id.

To run one of the applications with Xunify

1) Start Xunify

2) Add hosts

   Use the "Hosts..." menu to add one host for every worker you would
   like, plus one extra host (e.g., 4 workers => 5 machines).

3) Launch the program

   Select "SPAWN" from the "Tasks..." menu.  Click on the "Host"
   button under the "Where" label.  Type the name of the host on which
   Xunify was launched in the "Host" text field.  Next, type the name
   the commandline used to invoke the program in the "Command:" text
   field.  For example, to run matmul with 4 workers type

        matmul -- -n 4

   Click on the "Start" button to start the program.

   All of the example applications produce output in the directory in
   which they were compiled and your home directory.  The application
   generates one file in your home directory for each worker process,
   start.p, where p is one less than the worker number of the process.
   After the program has finished initialization, each worker writes a
   file into the directory in which the program was compiled named
   output.n.p, where n is the number of workers and p is one less than
   the worker id.
