因此,我最终清除了C文件中的所有错误和警告,并继续将它们链接起来。 我有2 C文件,我需要链接编译器。有2个C文件,我需要链接编译器
et5ibwqm0.c intfac_fl.c
我提供的编译命令:
gcc -shared -o et5stcklib.so et5ibwqm0.o intfac_fl.o -L$FGLDIR/lib
不工作,我得到这个错误:
et5ibwqm0.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
尝试使用“file”命令查看它在“et51bwqm0.o”和“intfac_fl.o”上的报告。此外,它将有助于查看用于编译它们的命令。 – ash
编译器编译**链接器** ... – Olaf
@Olaf'gcc'命令隐藏了区别,因为它从选项中找出它是否应该编译或链接。 – Barmar