Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ strip(1) — NeXTstep 2.2

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ld(1)

cc(1)

STRIP(1)  —  UNIX Programmer’s Manual

NAME

strip − remove symbols and relocation bits

SYNOPSIS

strip [ option ] name ... 

DESCRIPTION

Strip removes the symbol table and relocation bits ordinarily attached to the output of the assembler and loader.  This is useful to save space after a program has been debugged. 

The effect of strip is the same as use of the −s option of ld(1). The options −S, −x, and −X have the same effect as the ld(1) options.

There are mutually exclusive options to strip(1) (except that −a or −d filename maybe used with one of −x, −S, or −X):

−s filename
Save the symbol table entries for the global symbols listed in filename.  The symbol names listed in filename must be one per line with no other white space in the file except the newlines on the end of each line. 

−d filename
Save the debugging symbol table entries for each source file name listed in filename.  The source file names listed in filename must be one per line with no other white space in the file except the newlines on the end of each line.  And they must be just the base name of the source file without any leading directories. 

−S ‘Strip’ the output by removing all symbols except locals and globals.  That is debugging symbols created by the −g option to cc(1) and other compilers.

−X Save local symbols except for those whose names begin with ‘L’. 

−x Do not preserve local (non-.globl) symbols in the output symbol table; only save external symbols. 

−A Save all global absolute symbols except those with a value of zero and that are not objective-C class symbols.  This is intended for use of programs that use rld(3) and only want the loaded code to use symbols from the shared libraries.

−gg Only strip the symbol segments produced by the (obsolete) −gg option of the compiler cc(1).

SEE ALSO

ld(1), cc(1)

LIMITATIONS

Not every layout of a Mach-O file can be stripped by this program.  But all layouts produced by the compiler system can be stripped. 

BUGS

The options and how they interplay or don’t interplay is a mess. 

NeXT Computer, Inc.  —  September 19, 1990

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026