next up previous
Next: Short example application programs Up: The Mesh Archetype Previous: Utility subroutines and functions

Compiling and linking

Fortran M version


This section describes how to compile and link a program based on the Fortran M implementation. It assumes that the Fortran M compiler (fm) [2, 1] is installed.

To compile and link a program based on the Fortran M implementation:

For example, to compile the skeleton program p0.FM shown earlier:

        fm -c p0.FM
        fm -c mesh_lib.FM
        fm -o p0.exe p0.o mesh_lib.o

Observe that the library routines and the main program file must be recompiled if any of the PARAMETERs in mesh_uparms.h are changed -- this is because of the static nature of Fortran 77, on which Fortran M is based.

Fortran M version with parallel I/O


To include the optional parallel I/O, compile all the provided C routines (.c files) with a C compiler and include the resulting .o files in the above link. See the sample Makefile for an example. The utility programs split and merge must be compiled separately.

Other implementations


Compilation is similar to that for Fortran M, but using the appropriate compiler and/or message-passing library. See the sample Makefile for an example.



Berna L Massingill
Mon Jun 8 19:35:58 PDT 1998