linux build commands

本文介绍了多种用于软件开发的工具,包括但不限于:查看共享库依赖(ldd)、列出目标文件符号(nm)、显示ELF文件信息(readelf)、从对象文件中获取信息(objdump)、打印文件中的字符串(strings)、展示调用图概要(gprof)、创建和操作归档文件(ar)、使用GCC编译C和C++代码等。这些工具对于理解程序的运行机制及进行高效的软件开发至关重要。
ldd               print shared library dependencies
nm                list symbols from object files
readelf          Displays information about ELF files
objdump          display information from object files                         objdump -d a.out
strings          print the strings of printable characters in files
gprof          display call graph profile data
ar               create, modify, and extract from archives                       ar cqs libhello.a hello.o

gcc               GNU project C and C++ compiler                                 gcc -c -o hello.o hello.c

                                                                                                       gcc -shared -fPIC -o libhello.so hello.c

                                                                                                       gcc -o hello main.c -static -L. -lhello

                                                                                                       gcc -o hello main.c -L. -lhello

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值