-qweakexp

Category

Object code control

Pragma equivalent

None.

Purpose

When used with the -qmkshrobj or -G option, includes or excludes global symbols marked as weak from the export list generated when you create a shared object.

Syntax

Read syntax diagramSkip visual syntax diagram
        .-weakexp---.   
>>- -q--+-noweakexp-+------------------------------------------><

Defaults

-qweakexp: weak symbols are exported.

Usage

See -qweaksymbol for a description of weak symbols.

Use the -qweakexp option with the -qmkshrobj or -G option. See the description of -qmkshrobj or -G for more information.

Predefined macros

None.

Examples

To compile myprogram.c into a shared object and prevent weak symbols from being exported, enter the following command:
xlc myprogram.c -qmkshrobj -qnoweakexp

Related information