如何处理链接器错误:错误 – 找不到-lgcc

这是我的makefile:
task0 : main.o numbers.o add.o
        gcc -m32 -g -Wall -o task0 main.o numbers.o add.o

main.o : main.c
        gcc -g -Wall -m32 -ansi -c -o main.c
numbers.o : numbers.c
           gcc -g -Wall -m32 -ansi -c -o numbers.c
add.o: add.s
      nasm -g -f elf -w+all -o add.o add.s
clean : 
       rm -f *.o task0

这是终端输出

gcc -m32 -g -Wall -o task0 main.o numbers.o add.o
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc.a when      searching for -lgcc
/usr/bin/ld: cannot find -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
collect2: error: ld returned 1 exit status
make: *** [task0] 1 הלקת

谁能解释一下lgcc是什么以及如何解决这个问题?

解决方法

(在评论中回答.见 Question with no answers,but issue solved in the comments (or extended in chat))

@Basil Starynkevitch写道:

You should install the gcc-multilib package

@Jekyll写道:

07001

相关文章

本程序的编译和运行环境如下(如果有运行方面的问题欢迎在评...
水了一学期的院选修,万万没想到期末考试还有比较硬核的编程...
补充一下,先前文章末尾给出的下载链接的完整代码含有部分C&...
思路如标题所说采用模N取余法,难点是这个除法过程如何实现。...
本篇博客有更新!!!更新后效果图如下: 文章末尾的完整代码...
刚开始学习模块化程序设计时,估计大家都被形参和实参搞迷糊...