strip

Name

strip -- remove unnecessary information from executable files

Description

The specification for "strip" is as specified in the SUS but with the following differences as listed below.

Differences

-F bdfname, --target=bfdname

Treat the original objfile as a file with the object code bfdname, and rewrite it in the same .

-I bfdname, --input-target=bfdname

Treat the original objfile as a file with the object code bfdname.

-O bdfname, --output-target=bfdname

Replace objfile with a file in the output bfdname.

-R sectionname, --remove-section=sectionname

Remove the named section from the file. This option may be given more than once. Note that using this option inappropriately may make the object file unusable.

-s, --strip-all

Remove all symbols.

-S, -g, --strip-debug

Remove debugging symbols only.

--strip-unneeded

Strip all symbols that are not needed for relocation processing.

-N symbolname, --strip-symbol=symbolname

Remove symbol symbolname from the source file. This option may be given more than once, and may be combined with other strip options.

-o file

Put the stripped output in file, rather than replacing the existing file. When this argument is used, only one objfile argument may be specified.

-p, --preserve-dates

Preserve the access and modification dates of the file.

-x, --discard-all

Remove non-global symbols.

-X, --discard-locals

Remove compiler-generated local symbols. (These usually start with `L' or `.'.)

-K symbolname, --keep-symbol=symbolname

Copy only symbol symbolname from the source file. This option may be given more than once.

-N symbolname, --strip-symbol=symbolname

Do not copy symbol symbolname from the source file. This option may be given more than once, and may be combined with strip options other than -K.

-v, --verbose

Verbose output: list all object files modified. In the case of archives, strip -v lists all members of the archive.

--version

Show the version number for strip and exit.