<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Feb 19, 2016 at 11:09 AM, Frank Winter via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Solved. Recompiling LLVM with "-fno-rtti -fPIC" and building my application with "-fno-rtti" solved the issue.<br></blockquote><div><div><br></div><div>LLVM should already set -fno-rtti by default. I think re-compiling your app with -fno-rtti is what fixed the undefined typeinfo symbol errors.</div></div><div><br></div><div>It looks like you are linking LLVM static libs into a shared library, so you also needed to build LLVM with -fPIC. The documented way of doing this is to pass -DLLVM_ENABLE_PIC=ON to cmake.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
As a result of this experiment I conclude that the LLVM library cannot be used in applications that make use of RTTI. I guess that's a bug.</blockquote><div><br></div><div>You can enable RTTI by passing -DLLVM_ENABLE_RTTI=ON to cmake. This is documented here:</div><div><a href="http://llvm.org/docs/CMake.html#llvm-specific-variables">http://llvm.org/docs/CMake.html#llvm-specific-variables</a><br></div><div><br></div><div>It sounds like the real bug is "make the build documentation less confusing". Sorry about that. =/</div></div></div></div>