COBOL System Interface [ Micro Focus COBOL for UNIX COBOL User Guide ] MPE/iX 5.0 Documentation
Micro Focus COBOL for UNIX COBOL User Guide
COBOL System Interface
Access to the major components of the Micro Focus COBOL compilation
system - the Compiler, the native code generator and the system linker -
is via a single command: cob. Files specified to this command can be
any mixture of COBOL source, intermediate code, native code, linkable
object code, C source files or assembler source files. By default, the
cob command converts the specified COBOL source files into intermediate
code files which are suitable for animation; that is, files which can be
executed under the control of Animator. However, depending on the option
you specify to it, the cob command can output native code, intermediate
code, dynamically linked or statically linked executable modules.
Compiling
The Micro Focus COBOL Compiler compiles COBOL source code into
intermediate (.int) code. This intermediate code is a sequence of
instructions to an abstract Micro Focus COBOL machine. Information files
for use by Animator (.idy) are also created.
Animating
Animator is an interactive program debugging tool for use with Micro
Focus COBOL programs.
Generating
The native code generator translates and optimizes the intermediate code
(.int) produced by the Compiler into native code (.gnt or .o) for your
processor.
Linking
If you wish to link your program, for example if you are mixing C
programs with your COBOL programs, then you use the cob command. This
automatically invokes the system linker provided with your UNIX system to
link the required run-time support libraries to your native code object
files and create one executable file.
Since you would not normally create linkable object code, linking is not
discussed in this chapter.
Running
The run-time system (RTS) loads files of intermediate or native code. If
both .int and .gnt code is available, then by default, the RTS passes
native code to your processor for direct execution. It can execute
intermediate code interpretively if you select this option. The RTS also
acts as the interface between your Micro Focus COBOL program and such
operating system functions as file and device handling and memory
management.
Your COBOL system provides everything you need to develop modern COBOL
applications to run under UNIX. It also provides for problem-free
migration of COBOL applications from a large number of other systems and
dialects, including IBM mainframe COBOL, to UNIX.
Before reading this guide you should have read your Getting Started book,
which guides you through installing the COBOL system and gives a brief
overview of using it.
This chapter guides you through the normal basic process for creating
executable files from COBOL source code; from compiling your programs to
shipping completed applications to your end-users. Refer to your COBOL
System Reference for full details of operating the Compiler and Animator,
and of Running your programs. Refer to your Getting Started for details
of the development cycle using the menu system and differences in the
files created and used when Toolset components are installed.
MPE/iX 5.0 Documentation