編譯鏈接的過(guò)程命令
gcc -E hello.c -o hello.i 預(yù)處理
gcc -S hello.i -o hello.s 編譯,輸出的是匯編
gcc -c hello.s -o hello.o 匯編,輸出的是機(jī)器碼
gcc hello.o -o hello.exe 鏈接,輸出可執(zhí)行文件
簡(jiǎn)化的常用命令
gcc hello.c 直接生成a.exe
gcc hello.c -o test 生成test.exe
gcc hello1.c hello2.c -o test 多文件生成test.exe