Debian Codegraph @

fort77.1

raw
1 .Id $Id: fort77.1,v 1.1 1994/11/01 16:53:38 ig25 Exp ig25 $
2 .TH FORT77 1 "Nov 1996" Linux "Linux Programmer's Manual"
3 .SH NAME
4 fort77 \- invoke f2c Fortran translator transparently, like a compiler
5 .SH SYNOPSIS
6 .B fort77
7 .RB [ -c ]
8 .RB [ -g ]
9 .RB [ -v ]
10 .RB [ -k ]
11 .RB [ -P ]
12 .RB [ -cpp ]
13 .RB [ "f2c option ..." ]
14 .RB [ -L
15 .IR "directory ..." ]
16 .RI [ "gcc-option ..." ]
17 .RI [ "link option ..." ]
18 .RB [ -O
19 .IR optlevel ]
20 .RI [ -o
21 .IR outfile ]
22 .RB [ -s ]
23 .RB [ -w ]
24 .RB [ -Wx,arg1 [ ,arg2 ]...]
25 .I "file ..."
26 .SH DESCRIPTION
27 The
28 .B fort77
29 script invokes the
30 .B f2c
31 command transparently, so it can be used like a real Fortran compiler.
32 It can be used to compile Fortran, C and assembler code, and to link
33 it with the f2c libraries.
34 .PP
35 File arguments ending with
36 .B .f
37 are compiled as Fortran source files.
38 Files which end with
39 .B .P
40 are passed through to f2c, and files ending with
41 .B .F
42 are passed to the C preprocessor (invoked as
43 .RB """" "/lib/cpp -traditional" """")
44 first. Any switches passed via
45 .B -D
46 will be passed to the preprocessor.
47 If the translation is successful, the resulting C files will be passed to
48 .I cc
49 for translation into an object file.
50 Files ending in
51 .BR .c ,
52 .BR .C ,
53 .BR .cc ,
54 .BR .i ,
55 .BR .s ,
56 .BR .S ,
57 .BR .m ,
58 .BR .cc
59 or
60 .B .cxx
61 are passed to the GNU C compiler directly; see
62 .IR gcc(1) .
63 All other files are passed to the linker.
64 .SH OPTIONS
65 .TP 8
66 .B -c
67 Supress linking and produce an object (
68 .B .o
69 ) file from each source file.
70 .TP 8
71 .B -g
72 Include debugging information.
73 .B -v
74 Be verbose; supplying this twice will also tell the C compilers
75 etc to be verbose.
76 .TP 8
77 .B -k
78 Keep the C files generated by f2c around.
79 .TP 8
80 .B -cpp
81 Pass Fortran code through the C preprocessor, as if filenames
82 ended in
83 .BR .F .
84 .TP 8
85 .BR -P
86 Generate f2c
87 .I ".P "
88 files.
89 .TP 8
90 .BI -L directory
91 Include
92 .I directory
93 in the search for libraries in the final linking stage.
94 .TP 8
95 .B "-o outfile"
96 Send output to
97 .BR outfile .
98 .TP 8
99 .B -trapuv
100 Have f2c generate code to trap uninitialized values.
101 .TP 8
102 .BR -Wx,arg1 [, arg2 ...]
103 Pass the argument[s]
104 .B argi
105 through to the subprocess
106 .BR x ,
107 where
108 .B x
109 can assume one of the following values:
110 .B f
111 for the f2c step,
112 .B p
113 for the preprocessing step,
114 .B c
115 for the C compiler,
116 .B a
117 for the assembler (this is actually passed to the C compiler, too), and
118 .B l
119 for the linker.
120 As an example, defining a preprocessor constant for the C compilation
121 step would be done with
122 .BR "-Wc,-DUNIX=1" .
123 Specifying the
124 .B -f
125 option to f2c would be done via
126 .BR "-Wf,-f" .
127 .TP 8
128 .B "f2c option"
129 .B fort77
130 passes through almost all
131 .B f2c
132 options:
133 .BR -C ,
134 .BR -U ,
135 .BR -u ,
136 .BR -a ,
137 .BR -E ,
138 .BR -h ,
139 .BR -P ,
140 .BR -R ,
141 .BR -r ,
142 .BR -z ,
143 .BR -I2 ,
144 .BR -I4 ,
145 .BR -onetrip ,
146 .BR -!c ,
147 .BR -!l ,
148 .BR -!P ,
149 .BR -!R ,
150 .BR -ext ,
151 .BR -!bs ,
152 .BR -W[n] ,
153 .BR -trapuv ,
154 .BR -w8 ,
155 .BR -r8
156 and
157 .BR -w66 .
158 .TP 8
159 .B "gcc options"
160 The following options are passed through to gcc:
161 .BR -f* ,
162 .BR -W* ,
163 .BR -U* ,
164 .BR -A* ,
165 .BR -m* ,
166 .BR -S ,
167 .BR -E ,
168 .BR -v ,
169 .BR -x ,
170 .BR -pipe ,
171 .BR -o ,
172 .BR -I ,
173 .BR -V ,
174 .BR -b* ,
175 .BR -p ,
176 .BR -pg .
177 .TP 8
178 .B "linker option"
179 The options passed to the linking stage are
180 .BR -static ,
181 .BR -shared ,
182 .BR -v ,
183 .BR -V ,
184 and
185 .BR -symbolic .
186 .SH BUGS
187 To make debugging work, you need to set a breakpoint at
188 .B MAIN__
189 before you start.
190 .PP
191 .B f2c
192 This script automatically supplies the
193 .B -I.
194 option to
195 .BR f2c .
196 Older versions of
197 .BR f2c
198 may not support this.
199 .PP
200 This script is for the interaction of gcc and f2c; using it with
201 another compiler will probably require modification.
202 .PP
203 The
204 .B fort77
205 script does not strictly conform to Posix.2, because it acceppts
206 long options with one leading slash. This is done for gcc
207 compatibility.
208 .SH SEE ALSO
209 .BR f2c (1),
210 .BR cc (1),
211 .BR as (1),
212 .BR ld (1)
213 .SH AUTHOR
214 Thomas Koenig, [email protected]