Hello1.cpp:1:10: fatal error: 'llvm/Pass.h' file not found #include "llvm/Pass.h" ^ 1 error generated. Please help -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170119/dc5aff73/attachment.html>
Why has your helloworld got a #include "llvm/Pass.h" in line 1? What are you trying to do? What command did you use to start llvm? What are the values of your environment variables? On Thu, Jan 19, 2017 at 4:10 PM, Siddharth Shankar Swain via llvm-dev < llvm-dev at lists.llvm.org> wrote:> Hello1.cpp:1:10: fatal error: 'llvm/Pass.h' file not found > #include "llvm/Pass.h" > ^ > 1 error generated. > > Please help > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170119/a6e7e396/attachment.html>
I think you're trying to add a pass to the pipeline. Clearly the compiler isn't getting the correct include path. If I'm not mistaken, the cmake build system should pick this up automatically if you put your pass somewhere in one of the correct directories within your llvm source tree and add the file to the corresponding CMakeLists.txt. The "correct directory" will depend on what your pass does (i.e. analysis, transformation, etc.). On Thu, Jan 19, 2017 at 2:10 PM, Siddharth Shankar Swain via llvm-dev < llvm-dev at lists.llvm.org> wrote:> Hello1.cpp:1:10: fatal error: 'llvm/Pass.h' file not found > #include "llvm/Pass.h" > ^ > 1 error generated. > > Please help > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170119/63fb2712/attachment.html>