什么是“条"?(GCC 应用程序)用于? [英] What is "strip" (GCC application) used for?

查看:29
本文介绍了什么是“条"?(GCC 应用程序)用于?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这个小应用有什么用?

在没有任何选项的情况下使用它会减少可执行文件的大小,但它是如何/做什么的?

When using it without any options reduces the size of the executables, but how/what it does?

推荐答案

来自(Mac OS X,但其他类似)手册页:

From the (Mac OS X, but others are similar) man page:

strip 删除或修改附加到输出的符号表汇编器和链接编辑器.这对于节省空间很有用程序已调试并限制动态绑定符号.

strip removes or modifies the symbol table attached to the output of the assembler and link editor. This is useful to save space after a program has been debugged and to limit dynamically bound symbols.

请注意有关调试程序之后"的部分,因为调试剥离的可执行文件确实非常.限制动态绑定符号"很少使用:它允许您通过删除指示实际代码所在位置的索引条目来使外部库中的某些函数无法访问.这也在手册页中进行了解释.

Note the bit about "after a program has been debugged" because debugging a stripped executable is very hard, indeed. The "limit dynamically bound symbols" is a rarer use: it lets you make some of the functions in an external library inaccessible by taking away the index entries that tell where the actual code is located. This is also explained in the man page.

在大多数情况下,磁盘既便宜又丰富,您根本就不会再为此烦恼了.但您可能希望它用于空间受限的情况,例如嵌入式设备、救援磁盘等.

As cheap and plentiful as disk is in most situation you simply wouldn't bother with this anymore. But you might want it for space constrained situation like embeded devices, rescue disks, etc.

这篇关于什么是“条"?(GCC 应用程序)用于?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆