XSF3 1L "30 January 1991"
Table of contents
xsf3 - a preprocessor and compiler interface for
the structured Fortran language SFTRAN3
xsf3
[-C] [-D] [-H] [-I:num] [-K]
[-L] [-M:num] [-N] [-P] [-Q] [-R] [-V]
[-W:num] [compiler and loader options]
file1 [file2 file3 ...]
xsf3
assumes that the files
file*.sf3
contain code written in SFTRAN3, a structured
Fortran language. Fortran code is produced and
placed in corresponding files
file*.f.
Log files are placed in
file*.sfl.
File dates and times are compared to determine
whether to preprocess the files
file*.sf3
or simply to run the Fortran compiler (this action
may be overriden by the
-R
option).
The global variables SF3FLAGS and FFLAGS may be
used to provide switches for
sf3
and the Fortran compiler as used inside
xsf3.
In addition, if the file
sf3.opt
exists in the current or HOME directory, its
contents will be appended to the command line.
Since options are scanned from left to right,
SF3FLAGS values will override any provided in the
sf3.opt
file.
Options may also be specified in the file
./xsf3rc
in the current directory, or if not found there,
in the login directory.
If both an initialization file and an environment
variable are specified, the environment variable
switches will be presented
to
sf3
first, overriding the same switches from the
startup file. Similarly, command line switches
override ones from both of these sources.
This program is distributed with the <PLOT79>
system.
All unrecognized options are passed through
verbatim to the Fortran compiler which may in turn
send them to the linker. To minimize conflict
with native compiler options, all options handled
by
xsf3
are written with upper-case letters.
If a native Fortran compiler option does conflict
with one of the above, it must be supplied inside
a quoted string argument with a leading backslash
or a leading brace pair. E.g.
{}-N
and
-N
will be passed to Fortran as
-N,
instead of to
sf3.
-
-C
-
Produce CDC-style code for READ/WRITE END and ERR
parameters.
-
-D
-
Debug; embed SFTRAN3 code as comments in Fortran
code output.
-
-E
-
Run the SFTRAN3 preprocessor, but do not invoke
the Fortran compiler or linker.
-
-H
-
Display a help file and terminate immediately.
-
-I:num
-
Set structure indentation to
num
(0 to 9).
-
-K
-
Keep
*.f
files after a successful compilation. By default,
they are deleted. If compilation fails, they are
still preserved.
-
-L
-
Set the LINEUP option which connects structure
begin/end with dotted lines in the
*.sfl
files.
-
-M:num
-
Set maximum lines per page to
num
(suggested: 58 for 6 lpi and
80 for 8 lpi); ignored when prettyprinting.
-
-N
-
Inhibit production of
*.sfl
files.
-
-P
-
Prettyprinted source code sent to
*.sfl
files instead of a
normal listing.
-
-Q
-
Quick mode; suppress reading of
.xsf3rc
files.
-
-R
-
Reprocess everything, even if
*.f
or
*.o
files are newer than
.sf3
files.
-
-W:num
-
Set
*.sfl
file line width to
num
(72 to 120).
The following would take the files form the
current directory matching the patterns
a*.sf3
and
*bar*.sf3,
produce Fortran code files, invoke the Fortran
compiler to produce object files, produce log
files of 72 column width, and retain the Fortran
files.
xsf3 -W:72 -K a*.sf3 *bar*.sf3
To preprocess, compile, and link a single complete
program in the file
foo.sf3,
this command suffices:
xsf3 -o foo foo.sf3
To preprocess and compile without linking:
xsf3 -c foo.sf3
To preprocess only:
xsf3 -E foo.sf3
-
/usr/local/plot79/sf3dir/*
-
files required to make
sf3
(includes executable file)
-
/usr/local/plot79/sf3
-
shell script
-
/usr/local/plot79/xsf3
-
shell script
-
${HOME}/.xsf3rc
-
customization file
-
./.xsf3rc
-
customization file
sf3 (1L)
SFTRAN/3 Installation Guide.
Nelson H. F. Beebe. 1980.
SFTRAN3
(Jet Propulsion Laboratory
Document no. 1846-98, Dec. 1, 1978).
Nelson H. F. Beebe, Ph.D.
Center for Scientific Computing
Department of Mathematics
220 South Physics Building
University of Utah
Salt Lake City, UT 84112
Tel: (801) 581-5254