Hi everyone, This is Ashwin. I have a mac running osx 10.8. I am new to LLVM and have the version 3.1 installed. I am trying to get some LLVM transform passes running on my machine. After having compiled the LLVM source without making changes to the configuration files I am able to run the LLVM gcc and clang. But I am having some trouble using the passes. I tried loading the hello pass inside the transform directory of the LLVM object tree. When I do an opt -load LLVMhello.dylib -help I dont see the registered pass listed. Further when I load the option I get an undefined symbol error from the linker. This is the command i issue and the output i get. bash-3.2$ opt -load LLVMHello.dylib < hello.bc > /dev/null Error opening 'LLVMHello.dylib': dlopen(LLVMHello.dylib, 9): Symbol not found: __ZN4llvm12FunctionPass14doFinalization$ | Referenced from: /usr/local/bin/../lib/LLVMHello.dylib | Expected in: flat namespace | in /usr/local/bin/../lib/LLVMHello.dylib | -load request ignored. I appreciate your help. Please help me fix it! regards, Ashwin. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120821/9072ec4b/attachment.html>
On 8/21/2012 3:52 PM, Ashwin kumar wrote:> Hi everyone, > > This is Ashwin. I have a mac running osx 10.8. I am new to LLVM and > have the version 3.1 installed. I am trying to get some LLVM transform > passes running on my machine. After having compiled the LLVM source > without making changes to the configuration files I am able to run the > LLVM gcc and clang. But I am having some trouble using the passes. I > tried loading the hello pass inside the transform directory of the > LLVM object tree. > > When I do an opt -load LLVMhello.dylib -help I dont see the registered > pass listed. Further when I load the option I get an undefined symbol > error from the linker. This is the command i issue and the output i get. >It turns out that, on OS X, using the installed tool makes it unusable for plugins. If you edit this line of Makefile.rules: ProgInstall = $(INSTALL) $(Install.StripFlag) -m 0755 so that it looks like this: ProgInstall = $(INSTALL) -m 0755 it should work after installing. -- Joshua Cranmer News submodule owner DXR coauthor -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120821/ee8c8fc6/attachment.html>
Thank you. The edit made no difference. I did a clean install and the same error is reported. Any other suggestions? regards, Ashwin On Aug 21, 2012, at 2:59 PM, Joshua Cranmer <pidgeot18 at gmail.com> wrote:> On 8/21/2012 3:52 PM, Ashwin kumar wrote: >> Hi everyone, >> >> This is Ashwin. I have a mac running osx 10.8. I am new to LLVM and have the version 3.1 installed. I am trying to get some LLVM transform passes running on my machine. After having compiled the LLVM source without making changes to the configuration files I am able to run the LLVM gcc and clang. But I am having some trouble using the passes. I tried loading the hello pass inside the transform directory of the LLVM object tree. >> >> When I do an opt -load LLVMhello.dylib -help I dont see the registered pass listed. Further when I load the option I get an undefined symbol error from the linker. This is the command i issue and the output i get. >> > > It turns out that, on OS X, using the installed tool makes it unusable for plugins. If you edit this line of Makefile.rules: > ProgInstall = $(INSTALL) $(Install.StripFlag) -m 0755 > > so that it looks like this: > ProgInstall = $(INSTALL) -m 0755 > > it should work after installing. > -- > Joshua Cranmer > News submodule owner > DXR coauthor > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev