CAVERNsoft G2 SGI-IRIX/Linux Installation Guide - Working with Globus

Introduction

This guide shows you how to build the networking libraries and the demo programs in the CAVERNsoft G2 distribution with the Globus libraries. The Globus libraries were separated from the CAVERNsoft G2 distribution, to reduce the size of the CAVERNsoft G2 distribution.
 

Table of Contents

  1. System Requirements
  2. Building and installing the CAVERNsoft libraries
  3. Building your own application
  4. Support
  5. Appendix A : Directory Structure
  6. Appendix B : Building the CAVERNsoft libraries with other options
  7. Appendix C : Compiling the demo programs with other options

 System Requirements

 The networking modules of CAVERNsoft G2 with globus were tested on the platforms listed below.
 
Platform  Version
SGI Irix Version 6.5
Linux Red Hat 6.1

Building and installing the CAVERNsoft libraries

The process has 4 main steps.

1. Downloading the distribution into a working directory

  1. Download the CAVERN distribution to a working directory. You should see the file CAVERNG2_xxx.tar.gz (where xxx is the version number) in your working directory.

  2.  
  3. Uncompress the distribution by using the command :
    gunzip CAVERNG2_xxx.tar.gz
  4. Untar the distribution with the command :
    tar -xvf CAVERNG2_xxx.tar
  5. The entire distribution will be placed in your working directory under the sub directory CAVERNG2_xxx.  If your working directory is /usr/tmp/CAVERN, then you will see the distribution in /usr/tmp/CAVERN/CAVERNG2_xxx. (where xxx is the version number of the distribution).

  6.  
  7. Now download the globus distribution also into the CAVERNG2_xxx. So if the CAVERN distribution is now in /usr/tmp/CAVERN/CAVERNG2_xxx, you should see the globus distribution (globus_distrib.tar.gz) in this directory.

  8.  
  9. Uncompress the globus distribution by using the command :
    gunzip globus_distrib.tar.gz
  10. Untar the distribution by using the command :
    tar -xvf globus_distrib.tar
Note : A brief description of the directories in the distribution is available in Appendix A
Now you can install the pre compiled CAVERNsoft G2 library that is contained in the distribution (go to Step 3 directly). If you want to first build the CAVERNsoft G2 libraries, go on to Step 2..

2. Building the CAVERNsoft libraries

  1. You will have to define an environment variable CAVERN_DISTRIB which should point to the location of the distribution. So if your working directory is /usr/tmp/CAVERN, then CAVERN_DISTRIB should point to /usr/tmp/CAVERN/CAVERNG2_xxx.
  2. For the Bourne and Korn shells use:
    CAVERN_DISTRIB=/usr/tmp/CAVERN/CAVERNG2_XXX; export CAVERN_DISTRIB
    For C shell and tcsh, use:
    setenv CAVERN_DISTRIB /usr/tmp/CAVERN/CAVERNG2_XXX
  3. Run the SETUP.yyyy file. This will set up the makefiles and compile scripts for your platform. Refer to the list below to find out which SETUP file you need to use.
  4. Platform SETUP File to Use
    SGI Irix SETUP.IRIX
    Linux SETUP.LINUX_X86
  5.  The table below lists the default compilers used to build the libraries. Edit the CPPCOMPILER macro in the Makefile to specify a compiler of your choice.

  6.  
    Platform Compiler used
    SGI Irix CC
    Linux g++
  7. Type:
    make everything_with_globus
  8. This will create the 32 bit pthreads version for Linux) and all  the pthreads and sprocs versions (32 bit, n32 bit and 64 bit) for SGI-IRIX.

    Advanced users, see Appendix B for more options on compiling the libraries.

    The networking libraries are now ready for use. Go to step 4 to build the demo programs.

3. Installing CAVERNsoft G2 in the deployment directory

If you need to make the CAVERNsoft networking APIs available to other users, you should install CAVERNsoft in a deployment directory which is separate from the working directory used in Step 2 . Alternatively, you may have skipped Steps 2  and you may want to simply install the pre compiled CAVERNsoft G2 library on your system. To do so follow the instructions below:

  1. Define an environment variable CAVERN_DISTRIB which points to the deployment directory.
    For example, if you want to deploy the distribution in /usr/local/CAVERNG2, then
    For the Bourne and Korn shells use
    CAVERN_DISTRIB=/usr/local/CAVERNG2; export CAVERN_DISTRIB
    For C shell and tcsh, use:
    setenv CAVERN_DISTRIB /usr/local/CAVERNG2
  2. Run the SETUP.yyyy file where 'yyyy' stands for the platform(See the table in Step 2.2). This will set up the Makefiles and compile scripts for your platform.

  3. Type "make install" at the command prompt in the working directory. This will copy all the required files to the /usr/local/CAVERNG2 directory. Go to Step 4 to build the demo programs.
4. Building the demo programs
The demo programs are a set of sample programs located in the 'demos' sub directory of the distribution. These demo programs are strictly for CAVERNsoft's networking APIs. The demo programs exist in four directories under the demos sub directory (db, network, misc, threads). A 'README' file in each directory (located in the 'docs' sub directory) describes the demo programs.

Before you build the demo programs, you should have installed CAVERNsoft G2 in a deployment directory.

To build the demo programs with the default options (32 bit pthreads) type
compile_demos pthreads 32 USE_GLOBUS
    Advanced users, see Appendix C for more options on compiling the demos.
The demo programs should now compile all the way through. Look into each directory and use the docs/README.html file to understand how the demos should be run.

 Building your own application

    You are now ready to write your own applications with CAVERNsoft G2. Click here to see a Sample Makefile.

    It demonstrates how you can compile and link a program test.cxx with CAVERNsoft G2.

    Type make to build your program.

 Support

If you have any problems, questions, or feedback please send email to cavern@evl.uic.edu

 Appendix A : Directory Structure

The CAVERNsoft distribution is organized into several sub directories. Each sub directory is described below.
 
Directory Description
demos contains sample programs that use the CAVERNsoft G2 version 1.2 networking APIs. 
globus contains the header files (for pthreads and sprocs) and pre compiled globus libraries for SGI IRIX and Linux.
globus_all, globus_build contains the globus distribution
include contains header files for CAVERNsoft G2 version 1.2
lib contains pre compiled library files of CAVERNsoft G2 for SGI IRIX, Linux, Solaris and Microsoft Windows
perf_daemon contains performance monitoring daemon server and a simple performance monitoring client.
src contains source code for CAVERNsoft G2 version 1.2
WIN32 contains the pthreads library

Appendix B : Building the CAVERNsoft libraries with other options

CAVERNsoft libraries can be built with or without the Globus libraries also. You can also build the libraries using different thread types (pthreads or sproc) or different binary types (32 bit, 64 bit or n32 bits). These options are not available for all platforms. The table below specifies the command to be used to build a certain type of library. The table also indicates whether a certain library type is available/relevant to that platform.

 (Y indicates that you can use the command for that platform, N implies that you cannot)
 

 Set of libraries 

Commands to use 

SGI -IRIX Linux
All CAVERNsoft G2 libraries without using the globus libraries  make everything Y Y
All CAVERNsoft G2 libraries using Globus Libraries make everything_with_globus Y Y
32 bit Globus Library with pthreads make globus_pthreads_32 Y Y
64 bit Globus Library with pthreads make globus_pthreads_64 Y N
New 32 bit Globus Library with pthreads make globus_pthreads_n32 Y N
32 bit Globus Library with sproc make globus_sproc_32 Y N
64 bit Globus Library with sproc make globus_sproc_64 Y N
 New 32 bit Globus Library with sproc make globus_sproc_n32 Y N
32 bit CAVERNsoft G2 Library with pthreads version of Globus make cavern_pthreads_32 Y Y
64 bit CAVERNsoft G2 Library with pthreads version of Globus make cavern_pthreads_64 Y N
New 32 bit CAVERNsoft G2 Library with pthreads version of Globus make cavern_pthreads_n32 Y N
32 bit CAVERNsoft G2 Library with sproc version of Globus make cavern_sproc_32 Y N
64 bit CAVERNsoft G2 Library with sproc version of Globus make cavern_sproc_64 Y N
New 32 bit CAVERNsoft G2 Library with sproc version of Globus make cavern_sproc_n32 Y N
32 bit CAVERNsoft G2 without Globus make cavern_pthreads_32_without_globus Y Y
64 bit CAVERNsoft G2 without Globus make cavern_pthreads_64_without_globus Y N
New 32 bit CAVERNsoft G2 without Globus make cavern_pthreads_n32_without_globus Y N

Appendix C: Compiling the demo programs with other options

If  you decide to use the Globus libraries with the CAVERNsoft libraries, you should use the command specified below. Likewise if you want to use a certain binary type or threads library, look up the table below and use the appropriate command.

(Y indicates that you can use the command for that platform , N implies that you cannot)
 
Description 
(binary type - thread type - with/ without globus)
Command to use SGI - IRIX Linux Solaris
32 bit pthreads without globus compile_demos pthreads 32 Y Y Y
64 bit pthreads without globus compile_demos pthreads 64 Y N N
n32 bit pthreads without globus compile_demos pthreads n32 Y N N
32 bit sproc without globus compile_demos sproc 32 Y N N
64 bit sproc without globus compile_demos sproc 64 Y N N
n32 sproc without globus compile_demos sproc n32 Y N N
32 bit pthreads with globus compile_demos pthreads 32 USE_GLOBUS Y Y N
64 bit pthreads with globus compile_demos pthreads 64 USE_GLOBUS Y N N
n32 bit pthreads with globus compile_demos pthreads n32 USE_GLOBUS Y N N