.\" Hey, EMACS: -*- nroff -*- .TH FCASPLIT 1 "Mar 12, 2008" .\" Please adjust this date whenever revising the manpage. .\" .SH NAME fcasplit \- tool to split source code into separate per\-routine files .SH SYNOPSIS .B fcasplit .RI "[ \-f " nmft " ] [ \-c " nmcc " ] [ \-a " nmas " ] [\-noh] [\-log] " .br .RI " [ +fo " incf " ] [ +co " incc " ] [ +ao " incs " ]" .br .RI " [ \-fo " optf " ] [ \-co " optc " ] [ \-ao " opts " ] " file.ext .PP .B fcasplit .IR file.ext " [ fca_n ] [ " optf " [ " optc " [ " opts .br .RI " [ " nmft " [ " nmcc " [ " nmas " ]]]]]]" .SH DESCRIPTION .PP \fBfcasplit\fP, used with a command line of either form shown above, splits file \fIfile.ext\fP having a mixture of FORTRAN / C / assembler routines into separate files n.f or n.c or n.s, "n" being the name of each routine, creating at the same time a shell script \fIfile\fP.shfca and a Make file \fIfile\fP.mkfca either of which can be used to compile all routines individually. All new files are generated in the current directory, even if the original \fIfile.ext\fP is in a different location. .PP NOTE that the program does not work on source code written without having it in mind, since \fBfcasplit\fP looks for special identifying lines in comments of the source code in the original file, as noted below. It is able to operate, for instance, on source code output by \fBnypatchy\fP. .PP Defaults are defined in \fBfcasplit\fP for the names by which the compilers are called in the generated shell script and Makefile; with the \-f, \-c, \-a options they could be changed. In Debian GNU/Linux, these defaults are \fBgcc\fP for the C compiler, \fBgfortran\fP for the FORTRAN compiler, and \fBas\fP for the assembler. .PP Defaults are also defined for the options with which they are called; with the \-fo, \-co, \-ao options they can be re\-defined; with the +fo, +co, +ao options they can be incremented. In Debian GNU/Linux, these defaults are "\-c \-g \-O2" for the C compiler, "\-c \-g \-O2 \-fno\-automatic" for the FORTRAN compiler, and "" (i.e., no flags) for the assembler. .PP To be backward compatible these options can also be specified by the positional parameters after the file\-name (as in the second form of the command shown above). .PP If the \-noh option is given (or if the first parameter after the file\-name is "fca_n") the identifying header line of each routine is not written out. If the \-log option is given the name of each routine is printed on standard output. .SH FILE FORMAT Each routine in the original file \fIfile.ext\fP must start with an identifying line: .br "CDECK ID>, " in cols. 1\-12 for FORTRAN .br "/*DECK ID>, " in cols. 1\-12 for C .br ";DECK ID>, " in cols. 1\-12 for assembler .br "DECK ID>, " in cols. 2\-12 or .br "DECK ID>, " in cols. 3\-12 for anything else .br "name" in cols. 13\-40 gives the name .br .PP In the last two cases, or if "name" contains an extension, the file created will be "name" without extension .f, .c or .s added to it and without an entry into the script. .PP A trailing blank terminates the name, symbol . followed by blank also terminates, symbols ; < # ! all terminate, symbol */ also terminates. .SH SEE ALSO .BR nycheck "(1), " nydiff "(1), " nyindex "(1), " .BR nylist "(1), " nymerge "(1), " nypatchy "(1), " .BR nyshell "(1), " nysynopt "(1), " nytidy "(1), " yexpand (1) .PP The reference manual for the Nypatchy suite of programs is available in compressed PostScript format at the following URL: .br .I http://wwwasdoc.web.cern.ch/wwwasdoc/psdir/p5refman.ps.gz .SH AUTHOR This manual page was written by Kevin McCarty for the Debian GNU/Linux system (but may be used by others), based on the help information printed by the \fBfcasplit\fP program when called with no arguments. Both \fBfcasplit\fP and this man page are licensed under the GNU General Public License, version 2 or later (at your choice). .SH COPYRIGHT Copyright (C) CERN, 1996, 1999 and Kevin B. McCarty, 2008.