STRIP(1) SysV STRIP(1)
NAME
strip - strip symbol and line number information from a common object
file
SYNOPSIS
strip [-l] [-x] [-b [-r] [-V] [ -Aa] filename . . .
DESCRIPTION
The strip command strips the symbol table and line number information
from common object files, including archives. Once this has been done,
no symbolic debugging access is available for that file; therefore, this
command is normally run only on production modules that have been
debugged and tested. By default, enough information is saved to allow
traceback information to be obtained from stripped files.
The amount of information stripped from the symbol table can be
controlled by using any of the options listed below:
OPTIONS
-l Strips line number information only; does not strip any symbol
table information.
-x Does not strip static or external symbol information.
-b Same as the -x option, but also does not strip scoping
information (e.g., beginning and end of block delimiters).
-r Does not strip static or external symbol information, or
relocation information.
-V Prints the version of the strip command executing on the
standard error output.
-Aa Strips .blocks and .lines sections of common object files so
that traceback information is no longer available.
If there are any relocation entries in the object file and any symbol
table information is to be stripped, strip complains and terminates
without stripping filename unless the -r option is used.
If you use strip on a common archive file [see ar(4)] the archive symbol
table and module table are removed. You must restore the archive symbol
table by executing ar(1) with the s option before the archive can be
link-edited by ld(1). strip produces appropriate warning messages when
this situation arises.
strip is used to reduce the file storage overhead taken by the object
file.
FILES
TMPDIR/strp* temporary files
TMPDIR is usually /usr/tmp but can be redefined by setting the
environment variable TMPDIR [see tempnam() in tmpnam(3S)].
DIAGNOSTICS
strip: name: cannot open
if name cannot be read.
strip: name: bad magic
if name is not an appropriate common object file.
SEE ALSO
ar(1), cc(1), ld(1), ts(1), tmpnam(3S), a.out(4), ar(4).