HP aC++/HP C A.06.25 Programmer's Guide
aCC -Wl,-v file.C
Passing Options to the Linker with -W
The following example links file.o and passes the option -a archive to the linker,
indicating that the archive version of the math library (indicated by -lm) and all other
driver-supplied libraries should be used rather than the default shared library:
aCC file.o -Wl,-a,archive -lm
Passing Multiple Options to the Linker with -W
The following example links file.o and passes the options -a , archive, -m, and
-v to the linker:
aCC -Wl,-a,archive,-m,-v file.o -lm
This case is similar to the previous example, with additional options. -m indicates that
a load map should be produced. The -v option requests verbose messages from the
linker.
Symbol Binding Options
The following -B options are recognized by the compiler to specify whether references
to global symbols may be resolved to symbols defined in the current load module, or
whether they must be assumed to be potentially resolved to symbols defined in another
load module.
A global symbol is one that is visible by name across translation unit boundaries. A
static symbol is one that is visible by name only within a single translation unit but is
not associated with a particular procedure activation. A locally defined symbol is a
global or static symbol with a definition in the translation unit from which it is being
referenced.
-Bdefault
-Bdefault
Global symbols are assigned the default export class. These symbols may be imported
or exported outside of the current load module. The compiler will access tentative and
undefined symbols through the linkage table. Any symbol that is not assigned to another
export class through use of another -B option (or the deprecated +O[no]extern
option) will have the default export class. The -Bdefault option may also be used
on a per symbol basis to specify exceptions to global -Bprotected, -Bhidden, and
-Bextern options.
Usage:
-Bdefault=symbol[,symbol...]
The named symbols are assigned the default export class.
Symbol Binding Options 117