C/C++ Programmer's Guide (G06.25+)

Using the HP Enterprise Toolkit (ETK) and Native
C/C++ Cross Compiler on the PC
HP C/C++ Programmer’s Guide for NonStop Systems429301-008
18-3
Online Help
Online Help
Online help is the only user documentation for the Enterprise Toolkit. The online help is
composed of the following components:
Context-sensitive help for GUI objects
Help topics, such as “Setting Compiler Options”
Glossary of terms
Tutorial introducing the application
An HTML help file named “Using Command-Line Cross Compilers on Windows”
Usage Guidelines
The native C/C++ cross compiler produces object code that runs only on G-series or
H-series systems in either the Guardian or the OSS environment.
Source code that is compilable by the native C and C++ compilers running on G-series
or H-series systems is also compilable by the native PC cross compiler, except for
these differences:
The default target platform for the PC cross compiler depends on the copy of the
compiler used. For compilers installed in G-series RVU folders, the default and
only accepted value is G-series TNS/R servers (-Wtarget=TNS/R).
For compilers installed in H-series RVU folders, the default is H-series TNS/E
servers (-Wtarget=TNS/E). To produce programs that run on G-series TNS/R
servers, specify the -Wtarget=TNS/R flag to the c89 utility.
The default target environment for the PC cross compiler is the OSS environment.
To produce programs that run in the Guardian environment, specify the
-Wsystype=guardian flag to the c89 utility.
The native C PC cross compiler supports embedded SQL. When you enable SQL,
HP C passes the SQL options you choose to cfe so that embedded SQL
statements are compilable. Additional options are required on the PC as well.
To use the C/C++ cross compiler, the source files must reside in the PC
namespace. Because the cross compiler runs on the PC, the compiler cannot see
files located on NonStop server nodes. Therefore, you must transfer your source
files from the server to the PC using file transfer protocol (FTP).
Once your source files are on the PC, they can be distributed anywhere in the PC
namespace. Likewise, any files that are output from the PC cross compilers can be
distributed anywhere in the PC namespace.
PC source files with #include path names use the backslash (\) separator.
These path names are correctly interpreted by the PC cross compilers. However,
PC path names cannot be used by the native compilers that run on NonStop
servers.