Split FORTRAN90 Source Files

F90SPLIT is a C program which reads a FORTRAN90 source code, and writes each module to a separate file. A module is considered to be a FORTRAN BLOCKDATA, FUNCTION, MODULE, PROGRAM or SUBROUTINE.

Procedure X is put in file X.f90.

Comments preceding a procedure, and not associated with a preceding procedure, are included with that procedure.

You cannot use the more elaborate END statements that include the procedure definition, such as "END FUNCTION ALPHA".


f90split myprog.f90


F90SPLIT is available in a C version and a FORTRAN90 version.

Related Data and Programs:

EXTRACT, a FORTRAN90 program which extracts a subroutine, function or module by name from a FORTRAN file.

F77SPLIT, a C program which can split a FORTRAN77 file, assigning each subroutine or function to a separate file.

FIXCON, a FORTRAN90 program which reads a FORTRAN file using FORTRAN77 continuation statements, and makes a copy that uses FORTRAN90 continuation instead.

HTMLINDEX, a C++ program which reads a C, C++, FORTRAN77, or FORTRAN90 file and writes a skeleton HTML page describing it, assuming that each subroutine includes a '!!' or 'cc' description line.

INCLUDE_FILES, a FORTRAN90 program which reads a FORTRAN program with INCLUDE statements, and makes a copy with the indicated files included.

INDEX, a C++ program which reads a FORTRAN program and prints every line that begins with a special index tag of '!!' or 'cc'.

Source Code:

Examples and Tests:

List of Routines:

You can go up one level to the C source codes.

Last revised on 05 December 2007.