clang:错误:没有这样的文件或目录错误

时间:2016-06-22 20:28:58

标签: c

编译项目时,编译器抛出了这条消息:

if ( . != "." ) /bin/mv math3dgraphics.o . 

ar rcv ./mathtools.a ./mathtools.o ./matrix.o ./matrixtools.o ./pscmds.o ./pccurvecmds.o ./math3dgraphics.o
r - ./mathtools.o
r - ./matrix.o
r - ./matrixtools.o
r - ./pscmds.o
r - ./pccurvecmds.o
r - ./math3dgraphics.o
ranlib ./mathtools.a
/usr/bin/gcc -g -o -I/opt/X11/include xrna xrna.o xrnainit.o xrnatools.o xrnadisplay.o xrnamenu.o xrnalabels.o xrnalw.o xrnasstr.o xrnapccurve.o xrnatube.o xrnassymbols.o xrnatstr.o xrnabasepair.o xrnacon.o xrnathred.o xrnacolorwidget.o xrnastred.o xrnainquire.o tdhrefnuc.o xrnabuttonmenu.o grplinebuttonlist.o grplinefnclist.o grpparallelogrambuttonlist.o grpparallelogramfnclist.o grptextbuttonlist.o grptextfnclist.o grptrianglebuttonlist.o grptrianglefnclist.o grparcbuttonlist.o grparcfnclist.o grparrowbuttonlist.o grparrowfnclist.o transformbuttonlist.o transformfnclist.o xrnaprintbuttonlist.o xrnaprintfnclist.o xrnagraphics.o xrnaneutronmap.o xrnaalign.o helixtools.o helixio.o helixarc.o ./botif.a ./mathtools.a -DMATHHFILE='"./mathtools.h"' -L/opt/X11/lib -lX11 -lm -lg -lc -I/opt/X11/include
clang: error: no such file or directory: 'xrna'

make[1]: *** [install] Error 1

make: *** [xrna] Error 2

令我困惑的是xrna是应该生成的可执行文件,但为什么编译器说它丢失了?

1 个答案:

答案 0 :(得分:1)

在link语句中使用-o选项时,下一个条目必须是要输出的文件的名称,而不是某些库选项。