'\" te .\" Copyright 1989 AT&T .\" Copyright (c) 2009, 2011, Oracle and/or its affiliates.All rights reserved. .\" Portions Copyright (c) 1992, X/Open Company Limited All Rights Reserved .\" 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 http://www.opengroup.org/bookstore/. .\" 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.This notice shall appear on any product containing this material. .TH dis 1 "2011 年 6 月 8 日" "SunOS 5.11" "用户命令" .SH 名称 dis \- 对象代码反汇编程序 .SH 用法概要 .LP .nf \fBdis\fR [\fB-onqCLV\fR] [\fB-d\fR \fIsec\fR] [\fB-D\fR \fIsec\fR] [\fB-F\fR \fIfunction\fR] [\fB-l\fR \fIstring\fR] [\fB-t\fR \fIsec\fR] \fIfile\fR... .fi .SH 描述 .sp .LP \fBdis\fR 命令会产生 \fIfile\fR 的汇编语言列表,file 可以是目标文件或目标文件的归档文件。该列表包括汇编语句以及产生这些语句的二进制文件的八进制或十六进制表示形式。 .SH 选项 .sp .LP 各选项由反汇编程序解释,并可按任意顺序指定。 .sp .LP 支持以下选项: .sp .ne 2 .mk .na \fB\fB-C\fR\fR .ad .RS 15n .rt 显示反汇编中取消改编的 C++ 符号名称。 .RE .sp .ne 2 .mk .na \fB\fB-d\fR \fIsec\fR\fR .ad .RS 15n .rt 将指定部分作为数据反汇编,输出该数据从开头到该部分的偏移。 .RE .sp .ne 2 .mk .na \fB\fB-D\fR \fIsec\fR\fR .ad .RS 15n .rt 将指定部分作为数据反汇编,输出该数据的实际地址。 .RE .sp .ne 2 .mk .na \fB\fB-F\fR \fIfunction\fR\fR .ad .RS 15n .rt 仅反汇编在命令行上指定的每个目标文件中的指定函数。可以在命令行上多次指定 \fB-F\fR 选项。 .RE .sp .ne 2 .mk .na \fB\fB-l\fR \fIstring\fR\fR .ad .RS 15n .rt 将 \fIstring\fR 指定的归档文件反汇编。例如,发出命令 \fBdis\fR \fB-l\fR \fBx\fR \fB-l\fR \fBz\fR 可以对 \fBlibx.a\fR 和 \fBlibz.a\fR 反汇编(假设这两者在 \fBLIBDIR\fR 中)。 .sp 该选项已废弃,以后的 Solaris 版本中将不再包括。 .RE .sp .ne 2 .mk .na \fB\fB-L\fR\fR .ad .RS 15n .rt 调用在符号表中查找 C 语言标签,用于后续的写入到标准输出。 .sp 该选项已废弃,以后的 Solaris 版本中将不再包括。 .RE .sp .ne 2 .mk .na \fB\fB-n\fR\fR .ad .RS 15n .rt 以数字方式显示所有地址。缺省情况下,地址是使用符号名称显示的。 .RE .sp .ne 2 .mk .na \fB\fB-o\fR\fR .ad .RS 15n .rt 列显八进制数字。缺省设置是十六进制。 .RE .sp .ne 2 .mk .na \fB\fB-q\fR\fR .ad .RS 15n .rt 静默模式。不输出任何文件头或函数入口标签。 .RE .sp .ne 2 .mk .na \fB\fB-t\fR \fIsec\fR\fR .ad .RS 15n .rt 将指定部分作为文本反汇编。 .RE .sp .ne 2 .mk .na \fB\fB-V\fR\fR .ad .RS 15n .rt 在发生标准错误时列显正在执行的反汇编程序的版本号。 .sp 该选项已废弃,以后的 Solaris 版本中将不再包括。 .RE .sp .LP 如果指定了 \fB-d\fR、\fB-D\fR 或 \fB-t\fR 选项,则仅对每个用户指定的文件中的指定部分反汇编。否则,将对所有包含文本的部分反汇编。 .sp .LP 在输出时,在行的开头括在方括号中的数字(例如 \fB[5]\fR)指示可设置断点的行号用以下指令开始。这些行号仅在文件件汇编时附加了调试信息的情况下才会输出。 .SH 操作数 .sp .LP 支持下列操作数: .sp .ne 2 .mk .na \fB\fIfile\fR\fR .ad .RS 8n .rt 目标文件或目标文件的归档文件(请参见 \fBar\fR(1))的路径名。 .RE .SH 环境变量 .sp .LP 有关影响 \fBdis\fR 执行的环境变量 \fBLC_CTYPE\fR、\fBLC_MESSAGES\fR 和 \fBNLSPATH\fR 的说明,请参见 \fBenviron\fR(5)。 .sp .ne 2 .mk .na \fB\fBLIBDIR\fR\fR .ad .RS 10n .rt 如果此环境变量包含一个值,可将此用作搜索库的路径。如果该变量包含一个空值,或未设置该变量,则缺省为搜索 \fB/usr/lib\fR 下的库。 .RE .SH 退出状态 .sp .LP 将返回以下退出值: .sp .ne 2 .mk .na \fB\fB0\fR\fR .ad .RS 6n .rt 成功完成。 .RE .sp .ne 2 .mk .na \fB\fB>0\fR\fR .ad .RS 6n .rt 出现错误。 .RE .SH 文件 .sp .ne 2 .mk .na \fB\fB/usr/lib\fR\fR .ad .RS 12n .rt 缺省的 \fBLIBDIR\fR .RE .SH 属性 .sp .LP 有关下列属性的说明,请参见 \fBattributes\fR(5): .sp .sp .TS tab() box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . 属性类型属性值 _ 可用性developer/base-developer-utilities _ 接口稳定性请参见下文。 .TE .sp .LP 用户可读的输出是 "Uncommitted"(未确定)。命令行选项为 Committed(已确定)。 .SH 另请参见 .sp .LP \fBar\fR(1)、\fBas\fR(1)、\fBld\fR(1)、\fBa.out\fR(4)、\fBattributes\fR(5)、\fBenviron\fR(5) .SH 诊断 .sp .LP 诊断消息不需要加以说明,其指示命令行中的错误或者在指定文件中遇到的问题。