Calling a Preprocessor

The compiler option -Pg is used to call a preprocessor written in any language that produces a directly executable object file:

-Pg "preproc-1 [options]"

Here, preproc-1 is the name of the preprocessor's executable file. The compiler looks for this file first in the directory in which the compiler executable is located. We recommend that you place preprocessors in that directory. If you place them elsewhere, you need to provide a complete path specification. Under Windows, the compiler appends the extension .EXE automatically (if it is not already there).

The name of the preprocessor, and of any directories in its path, cannot contain spaces. Note that Windows creates a space-free alias for any name with embedded spaces. Every file and directory under Windows has an MS-DOS name and extension (maximum eight character name with a three character extension; the name can be viewed in the Properties dialog by right-clicking the file in the File Explorer). For example, the MS-DOS name and extension for acuodbcconfig.dll is ACUODB1.DLL. The MS-DOS name does not contain spaces, even if the original name does. The MS-DOS name and extension can be used by any Windows command or application in lieu of the original name and extension.

If the preprocessor requires or permits special options that are not specified by the ACUCOBOL-GT interface, they must follow the preprocessor executable file name and must be separated from it, and from each other, by spaces or tabs.

If a preprocessor option contains embedded spaces, it must be enclosed in delimiters so that it will be recognized as a single option. Standard double quotation marks (. . . ) cannot be used for this purpose because they are used to enclose the preprocessor executable filename and its associated options. Therefore, two apostrophes ('. . .') are used instead.

For example, the following option might be used to call a preprocessor:

-Pg "preproc -d ''x=:the quick brown fox'' "