9070 Remove wanboot from gate
[unleashed.git] / usr / src / man / man1 / strip.1
blob3b0196be607632f0cb5e17a045efa2cc5f6ae9e2
1 '\" te
2 .\" Copyright 1989 AT&T
3 .\" Copyright (c) 2007, Sun Microsystems, Inc.  All Rights Reserved
4 .\" Portions Copyright (c) 1992, X/Open Company Limited  All Rights Reserved
5 .\" Sun Microsystems, Inc. gratefully acknowledges The Open Group for permission to reproduce portions of its copyrighted documentation. Original documentation from The Open Group can be obtained online at
6 .\" http://www.opengroup.org/bookstore/.
7 .\" The Institute of Electrical and Electronics Engineers and The Open Group, have given us permission to reprint portions of their documentation. In the following statement, the phrase "this text" refers to portions of the system documentation. Portions of this text are reprinted and reproduced in electronic form in the Sun OS Reference Manual, from IEEE Std 1003.1, 2004 Edition, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 6, Copyright (C) 2001-2004 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between these versions and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html.
8 .\"  This notice shall appear on any product containing this material.
9 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
10 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
11 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
12 .TH STRIP 1 "Oct 5, 2007"
13 .SH NAME
14 strip \- strip symbol table, debugging and line number information from an
15 object file
16 .SH SYNOPSIS
17 .LP
18 .nf
19 \fBstrip\fR [\fB-lVx\fR] \fIfile\fR...
20 .fi
22 .SH DESCRIPTION
23 .sp
24 .LP
25 The \fBstrip\fR command removes the symbol table \fBSHT_SYMTAB\fR and its
26 associated string table, debugging information, and line number information
27 from \fBELF\fR object files. That is, besides the symbol table and associated
28 string table, the following sections are removed:
29 .sp
30 .in +2
31 .nf
32 \&.line
33 \&.debug*
34 \&.stab*
35 .fi
36 .in -2
37 .sp
39 .sp
40 .LP
41 Once this stripping process has been done, limited symbolic debugging access is
42 available for that file. Therefore, this command is normally run only on
43 production modules that have been debugged and tested.
44 .sp
45 .LP
46 If \fBstrip\fR is executed on a common archive file (see \fBar.h\fR(3HEAD)) in
47 addition to processing the members, \fBstrip\fR removes the archive symbol
48 table. The archive symbol table must be restored by executing the \fBar\fR(1)
49 command with the \fB-s\fR option before the archive can be linked by the
50 \fBld\fR(1) command. \fBstrip\fR produces appropriate warning messages when
51 this situation arises.
52 .sp
53 .LP
54 \fBstrip\fR is used to reduce the file storage overhead taken by the object
55 file.
56 .SH OPTIONS
57 .sp
58 .LP
59 The amount of information stripped from the  \fBELF\fR object file can be
60 controlled by using any of the following options. The following options are
61 supported:
62 .sp
63 .ne 2
64 .na
65 \fB\fB-l\fR\fR
66 .ad
67 .RS 6n
68 Strip line number information only.Does not strip the symbol table or debugging
69 information.
70 .RE
72 .sp
73 .ne 2
74 .na
75 \fB\fB-V\fR\fR
76 .ad
77 .RS 6n
78 Prints, on standard error, the version number of  \fBstrip\fR.
79 .RE
81 .sp
82 .ne 2
83 .na
84 \fB\fB-x\fR\fR
85 .ad
86 .RS 6n
87 Does not strip the symbol table. Debugging and line number information might be
88 stripped.
89 .RE
91 .SH OPERANDS
92 .sp
93 .LP
94 The following operand is supported:
95 .sp
96 .ne 2
97 .na
98 \fB\fIfile\fR\fR
99 .ad
100 .RS 8n
101 A path name referring to an executable file.
104 .SH ENVIRONMENT VARIABLES
107 See \fBenviron\fR(5) for descriptions of the following environment variables
108 that affect the execution of \fBstrip\fR: \fBLANG\fR, \fBLC_ALL\fR,
109 \fBLC_CTYPE\fR, \fBLC_MESSAGES\fR, and \fBNLSPATH\fR.
110 .SH EXIT STATUS
113 The following exit values are returned:
115 .ne 2
117 \fB\fB0\fR\fR
119 .RS 6n
120 Successful completion.
124 .ne 2
126 \fB\fB>0\fR\fR
128 .RS 6n
129 An error occurred.
132 .SH FILES
134 .ne 2
136 \fB\fB/tmp/strp*\fR\fR
138 .RS 14n
139 Temporary files
142 .SH ATTRIBUTES
145 See \fBattributes\fR(5) for descriptions of the following attributes:
150 box;
151 c | c
152 l | l .
153 ATTRIBUTE TYPE  ATTRIBUTE VALUE
155 Interface Stability     Standard
158 .SH SEE ALSO
161 \fBar\fR(1), \fBas\fR(1), \fBld\fR(1), \fBmcs\fR(1), \fBelf\fR(3ELF),
162 \fBtmpnam\fR(3C), \fBa.out\fR(4), \fBar.h\fR(3HEAD), \fBattributes\fR(5),
163 \fBenviron\fR(5), \fBstandards\fR(5)
164 .SH NOTES
167 The symbol table section is not removed if it is contained within a segment or
168 if the file is a relocatable object.
171 The line number and debugging sections are not removed if they are contained
172 within a segment or if their associated relocation section is contained within
173 a segment.
176 The \fBstrip\fR command is used to remove a standard predefined set of sections
177 from an ELF object file. To remove a user specified section by name, see
178 \fBmcs\fR(1).