I tried to build an LLVM pass in visual studio with cmake, but it seems add_LLVM_loadable_module macro doesn't support non-unix and non-cygwin platform. Is loadable module necessary for LLVM pass? Could I just build a static library and pass it to opt? If static library is not supported, is there any way to build an LLVM pass through visual studio? Or through clang with cmake? -- Thanks Thomson -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120617/a1ebc744/attachment.html>
NAKAMURA Takumi
2012-Jun-17 00:15 UTC
[LLVMdev] How to build an LLVM pass through visual studio
2012/6/17 Thomson <lilotom at gmail.com>:> I tried to build an LLVM pass in visual studio with cmake, but it seems > add_LLVM_loadable_module macro doesn't support non-unix and non-cygwin > platform. Is loadable module necessary for LLVM pass? Could I just build a > static library and pass it to opt? If static library is not supported, is > there any way to build an LLVM pass through visual studio? Or through clang > with cmake?Loadable module is not supported with CMake on Win32. FYI, as you know, on cygming (also mingw), "configure --enable-shared" is available. You cannot load external modules with opt. Instead, embed your pass in opt (lib/Analysis and lib/Transforms), and build opt. ...Takumi