/usr/bin/ld: i386:x86-64 architecture of input file `command.o' is incompatible with i386 output
出现这种警告的时候的时候,运行程序老是段错误,要加-m32,就好了。
gcc -m32 -o usehello_static usehello.c libhello.a
原因引用的库是 32位的,我是用的64位的系统
/usr/bin/ld: i386:x86-64 architecture of input file `command.o' is incompatible with i386 output
出现这种警告的时候的时候,运行程序老是段错误,要加-m32,就好了。
gcc -m32 -o usehello_static usehello.c libhello.a
原因引用的库是 32位的,我是用的64位的系统
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。