Programming tools / The preprocessor |
Preprocessor options can be used with fglcomp and fglform compilers.
-I path
The -I option defines a path used to search files included by the &include directives.
-D identifier
The -D option defines a macro with the value 1, so that it can be used conditional directives like &ifdef
-E
By using the -E option, only the preprocessing phase is done by the compilers. Result is dumped in standard output.
-p [nopp|noln|fglpp]
When using option -p nopp, it disables the preprocessor phase.
By using option -p noln with the -E preprocessing-only option, you can remove line number information and unnecessary empty lines.
By default, the preprocessor expects an ampersand '&' as preprocessor symbol for macros. The option -p fglpp enables the old syntax, using the sharp '#' as preprocessor symbol. The sharp '# ' syntax is not compatible with single-line comments.
fglcomp -E -D DEBUG -I /usr/sources/headers program.4gl
fglcomp -E -p fglpp -I /usr/sources/headers program.4gl
fglcomp -E -p nopp -I /usr/sources/headers program.4gl