cobol filename [filename]* [option]*
(+|-)Clear (-) Gstar=filename Hstar=filename (.h) Library=filename (+|-)Listing (-) (+|-)Map (-) Memory=nn (32) Name=name Object=filename Test=filename UpdateLib=filename USe=name (+|-)Zdebug (-)
cobol cobprog cobol cobsub u=tlib +c cobol cobprog l=tlib +map
The COBOL command provides you with a means of preparing Cobol 74 programs to run in TSS. The actual compilation is performed in batch by means of a DRL TASK. You can expect the compilation to take somewhat longer than the compilation of a Fortran program of equivalent size.
As a simple example, suppose "file1" contains Cobol source statements. To prepare the program for execution, you just say
cobol file1
To run the program, you use the GO command as in
go
COBOL will accept line-numbered programs. These line-numbers will be printed in error messages and on the compiler report (first file of the p*) if the +Listing option is in effect. The generated line-numbers will always be printed.
The rule for determining if a file is line-numbered is as follows: if the first character of the first line is a digit, the file is assumed to be line numbered.
The COBOL command makes certain assumptions about whether or not it needs to call the loader. Normally, it will call the loader to prepare a core image. If you specify an option that indicates you probably do not want the loader (e.g. "Object=" or "UpdateLib="), COBOL will not call the loader unless you also specify an option that pertains directly to the loader (such as "+Map", "USe=", or "Hstar=").
If you use the "UpdateLib=" option and also force the loader to be called, the Ranedit will be done after the load as a separate step.
The compiler listing and loader reports are written to a file called "p*". This is left in the AFT when the COBOL command returns.
Normally, you need not concern yourself with the contents of "p*", since COBOL will look at that file for you and print any error messages. However, if you do want to look at the reports, there are special procedures for doing so.
"p*" is a multi-file file. The first file is the compiler report. The second file contains the loader report or nothing, depending on what command options you used.
To inspect the first file is easy; just use the L or P command. To inspect the second file in order to look at the load map report, you should use the L or P command with the option "Fileskip=1".
expl cobol tss - how to use Cobol I/O in TSS.
compiler: b*, c*, *1, *2, *3, 5*, s*, g*, d*, p* loader: b*, *l, l*, r*, p*
Copyright © 1996, Thinkage Ltd.