Choose from the following for introductory information:
HP aC++ includes the following pieces:
- aCC -- the driver
- ctcom -- compiles C++ source statements
- assigner -- uses an automatic instantiation algorithm for template
processing (The assigner is not used by the default template instantiation
mechanism. It is invoked only when you specify +inst_auto or +inst_close
on the command-line.).
For More Information
To invoke the HP aC++ compiling system, use the aCC
command at the shell prompt. The aCC command invokes a driver program
that runs the compiling system according to the filenames and command line
options that you specify.
For More Information:
The best way to get started with HP aC++ is to write, compile, and
execute a simple program, like the following one:
#include
int main()
{
int x,y;
cout << "Enter an integer: ";
cin >> x;
y = x * 2;
cout << "\n" << y <<" is twice " << x <<".\n";
}
If this program is in the file getting_started.C, compiling and linking
the program with the aCC command produces an executable file named
a.out:
$ aCC getting_started.C
Executing the Program
To run this executable file, just enter the name of the file. The following
summarizes this process with the file named getting_started.C:
$ a.out
Enter an integer: 7
14 is twice 7.
You can use the HP WDB Debugger or the
HP/DDE Debugger
to debug your C++ programs.
To do so, first compile your program with either the
-g,
the -g0,
or the -g1 option.
Example
The -g0 option to aCC enables generation of debug information:
aCC -g0 program.C
The gdb command runs the HP WDB Debugger in terminal interface mode:
gdb -tui -xdb a.out
The dde command runs the HP/DDE Debugger:
dde a.out