Centos 7 編譯 32 bit C 代碼

  • 沒有 32 bit 的 libc

[root@s105 ~]# gcc -m32 test.c
In file included from /usr/include/features.h:399:0,
from /usr/include/stdio.h:27,
from test.c:1:
/usr/include/gnu/stubs.h:7:27: fatal error: gnu/stubs-32.h: No such file or directory
# include <gnu/stubs-32.h>
compilation terminated.

  • 安裝 glibc-devel.i686
yum install -y glibc-devel.i686
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章