Commit | Line | Data |
---|---|---|
d4f06e9c KB |
1 | .\" Copyright (c) 1983 The Regents of the University of California. |
2 | .\" All rights reserved. | |
49b2b382 | 3 | .\" |
d4f06e9c KB |
4 | .\" This code is derived from software contributed to Berkeley by |
5 | .\" Asa Romberger and Jerry Berkman. | |
6 | .\" | |
7 | .\" Redistribution and use in source and binary forms are permitted | |
8 | .\" provided that the above copyright notice and this paragraph are | |
9 | .\" duplicated in all such forms and that any documentation, | |
10 | .\" advertising materials, and other materials related to such | |
11 | .\" distribution and use acknowledge that the software was developed | |
12 | .\" by the University of California, Berkeley. The name of the | |
13 | .\" University may not be used to endorse or promote products derived | |
14 | .\" from this software without specific prior written permission. | |
15 | .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR | |
16 | .\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED | |
17 | .\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | |
18 | .\" | |
19 | .\" @(#)fsplit.1 6.2 (Berkeley) %G% | |
49b2b382 | 20 | .\" |
15ae4bc7 | 21 | .TH FSPLIT 1 "" |
49b2b382 KM |
22 | .UC 5 |
23 | .SH NAME | |
24 | fsplit \- split a multi-routine Fortran file into individual files | |
25 | .SH SYNOPSIS | |
26 | .B fsplit | |
27 | [ | |
28 | .B -e | |
29 | efile] ... [ file ] | |
30 | .SH DESCRIPTION | |
31 | .B Fsplit | |
32 | takes as input either a file or standard input containing Fortran source code. | |
33 | It attempts to split the input into separate routine files of the | |
34 | form | |
35 | .I name.f, | |
36 | where | |
37 | .I name | |
38 | is the name of the program unit (e.g. function, subroutine, block data or | |
39 | program). The name for unnamed block data subprograms has the form | |
40 | .I blkdtaNNN.f | |
41 | where NNN is three digits and a file of this name does not already exist. | |
42 | For unnamed main programs the name has the form | |
43 | .I mainNNN.f. | |
44 | If there is an error in classifying a program unit, or if | |
45 | .I name.f | |
46 | already exists, | |
47 | the program unit will be put in a file of the form | |
48 | .I zzzNNN.f | |
49 | where | |
50 | .I zzzNNN.f | |
51 | does not already exist. | |
52 | .PP | |
53 | Normally each subprogram unit is split into a separate file. When the | |
54 | .I -e | |
55 | option is used, only the specified subprogram units are split into separate | |
56 | files. E.g.: | |
57 | .nf | |
58 | fsplit -e readit -e doit prog.f | |
59 | .fi | |
60 | will split readit and doit into separate files. | |
61 | .SH DIAGNOSTICS | |
62 | If names specified via the | |
63 | .I -e | |
64 | option are not found, a diagnostic is written to | |
65 | .I standard | |
66 | .I error. | |
67 | .SH AUTHOR | |
68 | Asa Romberger and Jerry Berkman | |
69 | .SH BUGS | |
70 | .I Fsplit | |
71 | assumes the subprogram name is on the first noncomment line of the subprogram | |
72 | unit. Nonstandard source formats may confuse | |
73 | .I fsplit. | |
74 | .PP | |
75 | It is hard to use | |
76 | .I -e | |
77 | for unnamed main programs and block data subprograms since you must | |
78 | predict the created file name. |