<style id="sinamailpaperfilter">.sinamailpaper-0{cursor:text;}.sinamailpaper-0 td,.sinamailpaper-0 textarea,.sinamailpaper-0 input,.sinamailpaper-0 br,.sinamailpaper-0 div,.sinamailpaper-0 span{font-size:14px;font-family:"宋体",Verdana,Arial,Helvetica,sans-serif;line-height:1.5;}.sinamailpaper-0 p{*margin:0.2em auto;}.sinamailpaper-0 img{border:0;}.sinamailpaper-0 pre{white-space:normal;}.sinamailpaper-0 form{margin:0;}</style><P>Hi Eli,</P>
<P>Thanks for your rapid response!</P>
<P>Now I have another question.</P>
<P>How to get LLVM bc files successfully by compiling test.c and static libraries ? </P>
<P>Thanks a lot!</P>
<P><BR>----- 原始邮件 -----<BR>发件人:Eli Friedman <eli.friedman@gmail.com><BR>收件人:LLVM Developers Mailing List <llvmdev@cs.uiuc.edu><BR>主题:Re: [LLVMdev] [Need your help]<BR>日期:2008-10-18 01:05:03<BR><BR>On Fri, Oct 17, 2008 at 9:46 AM,  <kangjing820516@sina.com> wrote:<BR>> I tried to compile a C programme test.c with llvm-gcc by task:<BR>> [root@localhost mylib]# llvm-gcc -emit-llvm test.c -Llibmylib.a -c -o<BR>> test.bc<BR><BR>The -L flag doesn't do anything here.<BR><BR>> [root@localhost mylib]# lli test.bc<BR>><BR>> after running the command "lli test.bc",print the error info as follows:<BR>> ERROR: Program used external function 'gt' which could not be resolved!<BR>> lli[0x85c245f]<BR>> /lib/libc.so.6(abort+0x101)[0x6988b1]<BR>> lli(_ZN4llvm3JIT25getPointerToNamedFunctionERKSs+0xd2)[0x8267952]<BR>> Aborted<BR><BR>Of course; where do you expect it to find the function?<BR><BR>lli only supports loading LLVM bc files and dynamic libraries.<BR><BR>-Eli<BR>_______________________________________________<BR>LLVM Developers mailing list<BR>LLVMdev@cs.uiuc.edu         <A href="http://llvm.cs.uiuc.edu/" target=_blank>http://llvm.cs.uiuc.edu</A><BR><A href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" target=_blank>http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</A><BR></P><hr /><br /><a href = 'http://space.sina.com.cn/ '>新浪空间——与朋友开心分享网络新生活!</a>