[Contents] [Chapter 2] [Chapter 4] [Index]



Building a Compaq PVM Application

This chapter provides a description of how you modify a standard PVM application before you can run it with Compaq PVM. The chapter consists of the following sections:

3.1 Preparing a Standard PVM Application for Compilation with Compaq PVM

Before you compile and link a standard PVM application to run with Compaq PVM, there are a number of checks you may have to make to the standard PVM code:

  1. Check the functions in the application compiled for standard PVM against the list of Compaq PVM supported functions. (See Standard PVM Functions Supported in Compaq PVM.)

    Modify any standard PVM functions that are not supported by Compaq PVM to functions that are supported.

  2. Standard PVM applications typically expect to find header files in $(PVM_Root)/include. Compaq PVM places these include files in a system-wide directory and provides links to them from /usr/include. Thus these files will automatically be on the default search path of the C compiler.

    Check if your application uses a specific path to header files, for example, if the following command is used:

    include "~/pvm3/include/pvm3.h"

    If this is the case, modify the code to:

    include <pvm3.h>

    If your application has a line of code in the following format:

    include <pvm3.h>

    but uses the -I switch to the C compiler to locate the include file, the only modification you need to make is to the Makefile.

  3. Compaq PVM does not use the PVM make system (aimk). Instead, a simple, standard Makefile can be used.

  4. When you are building Compaq PVM applications, you do not need to place the executables in ~/pvm3/bin/$PVM_ARCH, but instead you can place them on the users' path. Compaq PVM does not use the PVM_ARCH environment variable.

3.2 Compiling an Application

Compaq PVM does not provide separate C and Fortran libraries. Both sets of functions are provided in the same library (libdpvm.a).

To compile and link standard PVM, follow these steps.

  1. Compile with the DEC™ C compiler (gemc).

  2. Enter the following command:

    # cc -o pvmtest pvmtest.c -ldpvm -lrt -pthread

    The library libdpvm.a must be used to link a C or Fortran program that contains PVM calls with Compaq PVM.

    To build a Compaq PVM application, link against libdpvm.a and librt.a (the real-time library from which some functions are used by the Compaq PVM code).


[Contents] [Chapter 2] [Chapter 4] [Index]


pvm@ilo.dec.com

Copyright © 1999, Digital Equipment Corporation. All rights reserved. Unpublished rights reserved under the copyright laws of the United States.