SQL/MX Programming Manual for C and COBOL (H06.10+, J06.03+)

COBOL Program Compilation
HP NonStop SQL/MX Programming Manual for C and COBOL544617-003
16-37
ecobol or nmcobol Utility: Using One Command for
All Compilation Steps
In addition to the options for preprocessing and compiling SQL/MX components,
ecobol and nmcobol supply SQL/MX environment variables that provide the path
names for the SQL/MX preprocessor (MXSQLCO) and the SQL/MX compiler (MXCMP
and MXCMPUM), in addition to the path name for definitions of the SQL call-level
interface (SQLCLIO). These CLI procedure calls, for the translated SQL statements in
the annotated COBOL source file, are required by the COBOL compiler. For more
information on ecobol and nmcobol environment variables, see the Open System
Services Shell and Utilities Reference Manual.
SQL/MX Preprocessing
Use the -Wsqlmx[=args] command to invoke the SQL/MX preprocessor. For a full
description of how the OSS-hosted SQL/MX preprocessor works, see OSS-Hosted
SQL/MX COBOL Preprocessor on page 16-13.
Compiling COBOL Statements
Use the ecobol utility to compile COBOL statements in a preprocessed file to create a
TNS/E native object file. On systems running H06.05 or later RVUs, use the nmcobol
utility to compile COBOL statements in a preprocessed file to create a TNS/R native
object file.
Your application program can run in the OSS or Guardian environment. Use the
ecobol or nmcobol -Wsystype=oss option (which is the default) if you want your
application to be an OSS program. Use the ecobol or nmcobol
-Wsystype=guardian option if you want your application to be a Guardian program.
For more information, see Building SQL/MX Guardian Applications in the OSS
Environment on page 16-47.
SQL/MX Compiling
Use the -Wmxcmp[=args] command to invoke the SQL/MX compiler. For a full
description of how to use the SQL/MX compiler, see Running the SQL/MX Compiler on
page 16-25.