C/C++ Programmer's Guide (G06.27+, H06.03+)

Table Of Contents
Compiler Pragmas
HP C/C++ Programmer’s Guide for NonStop Systems429301-010
13-104
SYSTYPE
SYSTYPE
The SYSTYPE pragma controls whether the generated code’s target execution
environment is the NonStop environment.
The pragma default settings are:
Usage Guidelines
The SYSTYPE pragma can be entered on the compiler RUN command line or be
specified with the -Wsystype flag of the c89 utility. A SYSTYPE pragma in the
source text does not change the target environment; it is only an affirmation of the
target environment.
The compiler issues an error if a SYSTYPE pragma specified in the source text
differs from:
°
The SYSTYPE pragma specified on the RUN command line.
°
The -Wsystype flag of the c89 utility.
°
The compiler default environment.
If you run the compiler in the Guardian environment, the default setting is SYSTYPE
GUARDIAN. If you run the compiler in the OSS environment (with the c89 utility),
the default setting is SYSTYPE OSS.
The SYSTYPE GUARDIAN and SYSTYPE OSS pragmas set the default values for
many other pragmas.
Pragma SYSTYPE GUARDIAN defines the _GUARDIAN_TARGET and
_TANDEM_SOURCE macros. Pragma SYSTYPE OSS defines the _OSS_TARGET and
_XOPEN_SOURCE macros. Because the SYSTYPE pragma defines and undefines
macros, you must specify the SYSTYPE pragma before any definitions in the RUN
command line or in a source file.
SYSTYPE { GUARDIAN | OSS }
Guardian Environment OSS Environment
TNS C compiler GUARDIAN N.A.
G-series TNS c89 utility N.A. OSS
TNS/R native C and C++ compilers GUARDIAN N.A.
Native c89 utility N.A. OSS
TNS/E native C and C++ compilers GUARDIAN N.A.