               README file for Ftnchek Version 2.5

Author: Robert Moniot
	Fordham University
	New York, NY  USA
	Bitnet:    MONIOT@FORDMULC
	Internet:  moniot@mary.fordham.edu

Date:	January 1992

Ftnchek is written in a portable style of C.  You must have a C
compiler for the machine on which you wish to run the program.

Version 2.5: Name changed from FORCHEK to FTNCHEK to avoid confusion
with a pre-existing commercial product called FORCHECK.  Bugs fixed.

Version 2.4: some bugs fixed, INCLUDE files accepted, EQUIVALENCE
statement processing, allow blanks in numeric constants.  NOTE: the
format of project files has been changed.  They are not compatible
with project files created by Version 2.3.

Version 2.3: a few more bugs fixed, and several syntax extensions added,
notably DO WHILE.  Project files added.

Version 2.2: two reported bugs in V.2.1 were fixed, and some features
were added.  See ftnchek.doc for details.

The file is shipped in the form of a "sh archive" or "shar" file.  You
should first concatenate all parts in order (if it was sent in
pieces), removing any mail headers.  Next, if you have a UNIX system,
simply feed it as input to the program "sh" to unpack it
automatically.  If you do not have a UNIX system, you will have to use
your text editor to clip out each file manually.  You will observe
that each line of every file has been prefixed with the letter X, and
all tabs have been converted to the grave accent (ASCII code 60
hexadecimal).  This was done to prevent clobbering during shipment
across network gateways.  You should use your editor to remove all
initial X's and to change all grave accents to tabs.

After accomplishing this step, you should find that you have received
the following set of source files:

        ftnchek.c       intrins.h       symtab.h
        ftnchek.h       iokeywds.h      symtab2.c
        forlex.c        prsymtab.c      tokdefs.h
        fortran.c       symtab.c

You should also have received the following auxiliary files:

        average.f     build.com     makefile.tc
        average.out   makefile

Documentation is in the files:

        ftnchek.doc   ftnchek.hlp   ftnchek.man   ftnchek.ps

The first is a flat text file.  Ftnchek.hlp is for making a help
library for VMS systems.  Ftnchek.man and ftnchek.ps are provided for
the convenience of those with access to nroff/troff or PostScript,
respectively.


VAX/VMS users should rename "AVERAGE.F" to "AVERAGE.FOR".
Once Ftnchek is working, you can test it by giving the command:

        $ ftnchek -list -sym average

Then compare the output against the file "average.out".  (Trailing
blanks have been removed from average.out due to shipping the Ftnchek
package across network gateways.)

To install Ftnchek, follow the instructions below for your operating
system.


(1) Unix

   Give the command:

        $ make



(2) VAX/VMS

   Give the command

        $ @BUILD

   After the program has been compiled, you must turn it into a
   so-called "DCL foreign command" so that it can be invoked by
   giving its name on a command line, instead of using the RUN
   command.  Do this with the command

        $ FTNCHEK :== $disk:[directory]FTNCHEK

   where you substitute the disk and directory names where the file
   FTNCHEK.EXE resides.  This command must be executed once per
   login.

   The BUILD procedure also creates a VMS help library named
   FTNCHEK.HLB.  To access it from the VMS HELP command, you must
   give the command

        $ DEFINE HLP$LIBRARY disk:[directory]FTNCHEK.HLB"

   Again, this command must be executed once per login to have effect.


(3) MS-DOS with Turbo C

   Rename the file "makefile.tc" to "makefile" and then give the
   command:

        C> MAKE



(4) Other systems

   It should suffice simply to compile all the ".c" files and link
   them.  The only differences among the versions for different
   operating systems have to do with the use of "/" vs. "-" as an
   option prefix, and the default filename extension ".FOR" vs. ".f".
   Selection among these options is done by defining a macro name for
   each system.  The VAX/VMS compiler pre-defines the macro name
   "VMS", while the Turbo C compiler pre-defines "__TURBOC__".
   Compilation without defining either of these macro names is the
   same as compiling with "UNIX" defined.

   To allow "/" as an option prefix, you can define the macro name
   "VMS", either as a commandline option to the compiler, or by
   altering the file ftnchek.h: just remove the commenting-out of
   the appropriate #define command found there.  In any case, "-" is
   always allowed as an option prefix.

   The default extension ".FOR" is assumed for VMS or Turbo C, ".f"
   for all others, unless you define the macro name
   "DEF_SRC_EXTENSION" otherwise on the compiler commandline or in
   ftnchek.h.  Other default values of Ftnchek's built-in parameters
   can be similarly modified on the compiler commandline.  See
   ftnchek.h for details.

   If your Fortran compiler supports many of the common I/O extensions
   found in VAX Fortran, you can compile the source using the compiler
   flag -DVMS_IO to cause Ftnchek to accept these extensions without
   assuming all other the VAX Fortran extensions and conventions.  The
   VAX I/O extensions include, for instance several additional control
   keywords for the OPEN statement, such as CARRIAGECONTROL, READONLY,
   etc.




