<div dir="ltr">Hi Mehdi,<div><br></div><div>I meant when I build the LLVM and it will give the following errors:</div><div><br></div><div><div>make[2]: Entering directory `/home/alex/new/llvm-obj/tools/llc'</div><div>llvm[2]: Linking Debug+Asserts executable llc</div><div>/home/alex/new/llvm-obj/Debug+Asserts/lib/libLLVMCodeGen.a(Passes.o): In function `llvm::TargetPassConfig::addIRPasses()':</div><div>/home/alex/new/llvm-3.1.src/lib/CodeGen/Passes.cpp:295: undefined reference to `llvm::createMyAliasAnalysisPass()'</div><div>collect2: ld returned 1 exit status</div><div>make[2]: *** [/home/alex/new/llvm-obj/Debug+Asserts/bin/llc] Error 1</div><div>make[2]: Leaving directory `/home/alex/new/llvm-obj/tools/llc'</div><div>make[1]: *** [llc/.makeall] Error 2</div><div>make[1]: Leaving directory `/home/alex/new/llvm-obj/tools'</div><div>make: *** [all] Error 1</div></div><div><br></div><div><br></div><div>Thanks,</div><div>Alex</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 4, 2015 at 5:17 PM, Mehdi Amini <span dir="ltr"><<a href="mailto:mehdi.amini@apple.com" target="_blank">mehdi.amini@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
> On Dec 4, 2015, at 1:37 PM, Alex S via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br>
><br>
> Hi all,<br>
><br>
> I create a folder containing my new alias analysis pass in the lib/Analysis folder of the source tree.<br>
> I mimic the way IPA did to create a LLVMipa.a library. That is, I write a Makefile to create my library<br>
> and I change the Makefile correspondingly in the Analysis folder.<br>
><br>
> However, when I want to use my new alias analysis in the Codegen. The compiler will complain<br>
> "undefined error" during the link phase.  Could anyone point me out where I need to change in order<br>
> to use my new alias analysis pass in the Codegen?<br>
<br>
<br>
</span>Can you provide the link command that fails and the output?<br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
Mehdi<br>
<br>
</font></span></blockquote></div><br></div>