静态库命令之间的区别
ar crf library.a file1.o file2.o
ar rvs library.a.a file1.o file2.o
ar rs liblprprint.a lpr_print.o
ar rcs library.a file1.o file2.o
实际上我已经用谷歌搜索了静态库,我发现这4个命令可用于在gcc中创建静态库。在stackoverflow的先前答案中搜索了2个命令。我想知道的是,有什么区别吗这4个命令之间?它们在创建静态库方面有什么不同吗?因为我们可以通过一条命令来创建静态库,但是为什么我们有4条命令来创建静态库。这些让我相信所有 4 个命令之间一定存在差异。我在 google 上尝试过,但他们给出了命令,但我没有找到它们之间的差异。所以有人知道为什么我们在创建时要处理 4 个命令静态库?它们之间有什么区别?我的意思是 rs、rcs、rvs,为什么我们有它们?
ar crf library.a file1.o file2.o
ar rvs library.a.a file1.o file2.o
ar rs liblprprint.a lpr_print.o
ar rcs library.a file1.o file2.o
Actually I have googled about the static library and I found these 4 commands that can be used to create a static library in gcc.Out of 2 are searched in the previous answers of stackoverflow .The thing I want to know is, Is there any difference between these 4 commands? Do they differ in creating a static library in any aspect. because we can follow one command to create a static library but why do we have 4 commands to create a static library. These made me believe there must be a difference between all the 4 commands.I tried it on google but they gave the command but i did not find the differnces between them.So does anybody know why do we got 4 commands to work on while creating a static library?What would be the difference between them? I mean rs,rcs,rvs, why we have them?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
来自
man ar
From
man ar