<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style id="owaParaStyle" type="text/css">
<!--
p
        {margin-top:0;
        margin-bottom:0}
p
        {margin-top:0;
        margin-bottom:0}
-->
P {margin-top:0;margin-bottom:0;}</style>
</head>
<body ocsi="0" fpstyle="1">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">Still no go. I'm going to experiment building out of source manually with the cmake build and autotools build. I should've mentioned that I'm attempting this with the hello world
 pass example.<br>
<br>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div style="direction: ltr;" id="divRpF601447"><font face="Tahoma" size="2" color="#000000"><b>From:</b> llvmdev-bounces@cs.uiuc.edu [llvmdev-bounces@cs.uiuc.edu] on behalf of Charles Jacobsen [charlie.jacobsen@utah.edu]<br>
<b>Sent:</b> Friday, June 14, 2013 8:25 AM<br>
<b>To:</b> llvmdev@cs.uiuc.edu<br>
<b>Subject:</b> Re: [LLVMdev] Building pass out of source with cmake: undefined symbol error<br>
</font><br>
</div>
<div></div>
<div>
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt">Hmmm, I just thought of something. Perhaps I need to set the MODULE cmake flag (via -DMODULE=ON)? I will try this today. (I remembered the LOADABLE_MODULE=1 flag in the makefile,
 and the if ( MODULE ) check in the AddLLVM cmake module.)<br>
<br>
<div style="font-family:Times New Roman; color:#000000; font-size:16px">
<hr tabindex="-1">
<div id="divRpF225154" style="direction:ltr"><font face="Tahoma" size="2" color="#000000"><b>From:</b> llvmdev-bounces@cs.uiuc.edu [llvmdev-bounces@cs.uiuc.edu] on behalf of Charles Jacobsen [charlie.jacobsen@utah.edu]<br>
<b>Sent:</b> Friday, June 14, 2013 7:55 AM<br>
<b>To:</b> llvmdev@cs.uiuc.edu<br>
<b>Subject:</b> [LLVMdev] Building pass out of source with cmake: undefined symbol error<br>
</font><br>
</div>
<div></div>
<div>
<div style="direction:ltr; font-family:Tahoma; color:#000000; font-size:10pt">
<div>After building the pass out of source with cmake, when I load it with opt, I get an undefined symbol error: _ZTIN4llvm12FunctionPassE undefined in the .so.
<br>
<br>
(_ZTVN4llvm12FunctionPassE is also undefined -- a "U" when I run nm. This symbol -is- in all of the llvm libraries.)<br>
<br>
Platform: ubuntu 12.10 LTS, x86 64<br>
gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3<br>
<br>
Build: LLVM 3.2 (svn), tried debug and release<br>
</div>
<div>Test suite builds and runs without error<br>
No other versions of llvm or clang are present<br>
</div>
<div><br>
I also tried building debug and release versions of the pass. No build errors or warnings when producing the pass .so.<br>
<br>
</div>
<div>I don't see this symbol in any of the llvm libraries, so I have no idea how it is being introduced into the pass .so.<br>
<br>
</div>
Interestingly, when I build llvm in source with autotools, and build the pass in source with the provided makefile template, it works, and _ZTIN4llvm12FunctionPassE is not in the pass .so. (Also, _ZTVN4llvm12FunctionPassE is now "B" when I run nm.).
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>