<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hello,<div><br></div><div>I have a question concerning llvm-c.</div><div>I have set up a function that needs to invoke an external method, in a other library. It has the following signature: void* NSFullUserName(void);</div><div>The void* can be replaced with a i8*, that far I was able to get, but when my call is invoked, the engine gives me the following message:</div><div><font class="Apple-style-span" face="Menlo" size="3"><span class="Apple-style-span" style="font-size: 11px;"><b><font class="Apple-style-span" face="Helvetica"><span class="Apple-style-span" style="font-weight: normal; font-size: medium;"><br></span></font></b></span></font></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 28px; text-indent: -28px; font: normal normal normal 11px/normal Menlo; "><b>LLVM ERROR: Tried to execute an unknown external function: i8* ()* NSFullUserName</b></div></div><div><br></div><div>I have dumped the module (without the clutter):</div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 28px; text-indent: -28px; font: normal normal normal 11px/normal Menlo; "><b>declare i8* @NSFullUserName()</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 28px; text-indent: -28px; font: normal normal normal 11px/normal Menlo; min-height: 13px; "><b></b><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 28px; text-indent: -28px; font: normal normal normal 11px/normal Menlo; "><b>define i8* @MyFunction() {</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 28px; text-indent: -28px; font: normal normal normal 11px/normal Menlo; "><b>entrypoint:</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 42px; text-indent: -42px; font: normal normal normal 11px/normal Menlo; "><b>  %myCall = call i8* @NSFullUserName()            ; <i8*> [#uses=1]</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 42px; text-indent: -42px; font: normal normal normal 11px/normal Menlo; "><b>  ret i8* %myCall</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 28px; text-indent: -28px; font: normal normal normal 11px/normal Menlo; "><b>}</b></div></div><div><br></div><div>Where am I going wrong here?</div><div><br></div><div>Thank you,</div><div><br></div><div>Filip</div></body></html>