日期:2014-05-16  浏览次数:20717 次

GCC 的相关的命令
arm-linux-addr2line 
 arm-linux-ar 
 arm-linux-as
 arm-linux-c++ 
arm-linux-c++filt 
arm-linux-cpp 
arm-linux-g++
arm-linux-gcc
arm-linux-gcc-4.3.2 
14:16 arm-linux-gcov 
arm-linux-gdb 
arm-linux-gdbtui 
arm-linux-gprof
 arm-linux-ld 
 arm-linux-nm
arm-linux-objcopy 
arm-linux-objdump 
 arm-linux-ranlib 
arm-linux-readelf 
arm-linux-size 
arm-linux-sprite 
arm-linux-strings 
arm-linux-strip 


高手们帮忙解释一下这些命令是干什么的?

我就知道arm-linux-gcc的步骤∶预处理(也称预编译,Preprocessing)、编译(Compilation)、汇编(Assembly) 和链接(Linking)。 

请教其他的

------解决方案--------------------
楼主先要理解什么叫交叉编译,再就是了解arm是一个平台
打个比方,有一个hello.c的文件,希望把它编译生成的可执行文件hello在arm平台上运行,怎么编译呢
最简单的方法是找一台arm平台的机器,在上面执行gcc hello.c -o hello,这当然可以
但如果没有arm机器,只有一台linux机器,怎么办呢,也可以的,就是用这里的arm-linux-gcc,
通过arm-linux-gcc hello.c -o hello,编译出来的hello,也可以在arm平台上运行(但这个hello虽然是linux上编译的,却不能在linux上执行)
在一个平台上编译另一个平台的程序,这就叫交叉编译

楼主列出的命令都属于此类。

有了交叉编译,只要给我一台linux机器,我就能发布很多平台,包括win32的程序了,方便吧
------解决方案--------------------
HTML code

       addr2line - convert addresses into file names and line numbers.
       ar - create, modify, and extract from archives
       as - the portable GNU assembler.
       gcc - GNU project C and C++ compiler
       cpp - The C Preprocessor
       gcov - coverage testing tool
       gdb - The GNU Debugger
       gprof -- display call graph profile data
       ld - Using LD, the GNU linker
       nm - list symbols from object files
       objdump - display information from object files.
       objcopy - copy and translate object files
       ranlib - generate index to archive.
       readelf - Displays information about ELF files.
       size - list section sizes and total size.
       strings - print the strings of printable characters in files.
       strip - Discard symbols from object files.

------解决方案--------------------
加入你用arm-linux-gcc创建了.o文件,难道准备用ar来建.a文件?

其余用法相同道理
------解决方案--------------------
想知道命令的含义?

举个例子,其余类推,呵呵

在Bash下键入命令:man gcc 【回车】

就可以看到详细解释。

接分哟!~~
------解决方案--------------------
google或者man一下就知道了

2楼的英文解释翻译一下也能了解大概