Specifies that a symbol can be accessed by other shared objects or executables.
Note:
A symbol can be exported only if the definition has STV_DEFAULT or STV_PROTECTED
visibility. You must use the --override_visibility command-line option to enable the linker to override
symbol visibility to STV_DEFAULT.
Syntax
EXPORTpattern AS replacement_pattern[,patternAS replacement_pattern]
where:
pattern
is a string, optionally including wildcard characters (either * or
?), that matches zero or more defined global symbols. If
pattern does not match any defined global
symbol, the linker ignores the command. The operand can match only defined global
symbols.
If the symbol is not defined, the linker issues:
Warning: L6331W: No eligible global symbol matches pattern
symbol
replacement_pattern
is a string, optionally including wildcard characters (either * or
?), to which the defined global symbol is to be renamed. Wild
characters must have a corresponding wildcard in
pattern. The characters matched by the
replacement_pattern wildcard are substituted
for the pattern wildcard.
For example:
EXPORT my_func AS func1
renames and exports the defined symbol my_func as
func1.
Usage
You cannot export a symbol to a name that already exists. Only one wildcard character
(either * or ?) is permitted in
EXPORT.
The defined global symbol is included in the dynamic symbol table (as
replacement_pattern if given, otherwise as
pattern), if a dynamic symbol table is present.
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers of your data.