BSD 3 development
[unix-history] / usr / man / man1 / f77.1
CommitLineData
fb8a6193
BJ
1.TH F77 1
2.SH NAME
3f77 \- Fortran 77 compiler
4.SH SYNOPSIS
5.B f77
6[ option ] ... file ...
7.SH DESCRIPTION
8.I F77
9is the UNIX Fortran 77 compiler.
10It accepts several types of arguments:
11.PP
12Arguments whose names end with `.f' are taken to be
13Fortran 77 source programs;
14they are compiled, and
15each object program is left on the file in the current directory
16whose name is that of the source with `.o' substituted
17for '.f'.
18.PP
19Arguments whose names end with `.r' or `.e' are taken to be Ratfor or EFL
20source programs, respectively; these are first transformed by the
21appropriate preprocessor, then compiled by f77.
22.PP
23In the same way,
24arguments whose names end with `.c' or `.s' are taken to be C or assembly source programs
25and are compiled or assembled, producing a `.o' file.
26.PP
27The following options have the same meaning as in
28.IR cc (1).
29See
30.IR ld (1)
31for load-time options.
32.TP
33.B \-c
34Suppress loading and produce `.o' files for each source
35file.
36.TP
37.B \-g
38Have the compiler produce additional symbol table information for
39.IR sdb (1).
40Also pass the
41.B \-lg
42flag to
43.IR ld (1).
44.TP
45.B \-z
46Create load-on-demand format output (an
47.IR ld (1)
48flag); this is important to specify when loading certain very large programs.
49See
50.IR ld (1).
51.TP
52.B \-p
53Prepare object files for profiling, see
54.IR prof (1).
55.TP
56.SM
57.B \-O
58Invoke an
59object-code optimizer.
60.TP
61.SM
62.B \-S
63Compile the named programs, and leave the
64assembler-language output on corresponding files suffixed `.s'.
65(No `.o' is created.).
66.TP
67.B \-f
68Use a floating point interpreter (for PDP11's that lack
6911/70-style floating point).
70.TP
71.BR \-o " output"
72Name the final output file
73.I output
74instead of `a.out'.
75.PP
76The following options are peculiar to
77.IR f77 .
78.TP
79.SM
80.BR \-onetrip
81Compile DO loops that are performed at least once if reached.
82(Fortran 77 DO loops are not performed at all if the upper limit is smaller than the lower limit.)
83.TP
84.BR \-u
85Make the default type of a variable `undefined' rather than using the default Fortran rules.
86.TP
87.BR \-C
88Compile code to check that subscripts are within declared array bounds.
89.TP
90.BR \-w
91Suppress all warning messages.
92If the option is `\-w66', only Fortran 66 compatibility warnings are suppressed.
93.TP
94.BR \-F
95Apply EFL and Ratfor preprocessor to relevant files, put the result in the file
96with the suffix changed to `.f', but do not compile.
97.TP
98.BR \-m
99Apply the M4 preprocessor to each `.r' or `.e' file before transforming
100it with the Ratfor or EFL preprocessor.
101.TP
102.TP
103.BI \-E x
104Use the string
105.I x
106as an EFL option in processing `.e' files.
107.TP
108.BI \-R x
109Use the string
110.I x
111as a Ratfor option in processing `.r' files.
112.PP
113Other arguments
114are taken
115to be either loader option arguments, or F77-compatible
116object programs, typically produced by an earlier
117run,
118or perhaps libraries of F77-compatible routines.
119These programs, together with the results of any
120compilations specified, are loaded (in the order
121given) to produce an executable program with name
122`a.out'.
123.SH FILES
124.nf
125.ta \w'/usr/lib/libF77.a 'u
126file.[fresc] input file
127file.o object file
128a.out loaded output
129./fort[pid].? temporary
130/usr/lib/f77pass1 compiler
131/lib/f1 pass 2
132/lib/c2 optional optimizer
133/usr/lib/libF77.a intrinsic function library
134/usr/lib/libI77.a Fortran I/O library
135/lib/libc.a C library, see section 3
136.fi
137.SH "SEE ALSO"
138S. I. Feldman,
139P. J. Weinberger,
140.I
141A Portable Fortran 77 Compiler
142.br
143prof(1), cc(1), ld(1)
144.SH DIAGNOSTICS
145The diagnostics produced by
146.I f77
147itself are intended to be
148self-explanatory.
149Occasional messages may be produced by the loader.
150.SH BUGS
151The Fortran 66 subset of the language has been
152exercised extensively;
153the newer features have not.