[cfe-dev] Multiple plug-ins in one shared lib?

Jordy Rose jediknil at belkadan.com
Sun Dec 25 01:39:22 PST 2011


Hi, Erik. AFAIK it's not yet possible to run multiple plugin actions from a single invocation of clang. This has nothing to do with where the actions come from; it's just how -plugin is handled.

Please file a bug at http://llvm.org/bugs with your expected behavior: do you want the plugins to be run serially on the original AST, or should they be able to return a new AST so they can act as filters of some kind, or...

(my guess is you just want the first one, but I thought I'd bring it up)

Jordy


On Dec 12, 2011, at 20:41, Erik Verbruggen wrote:

> Hello,
> 
> I could not find it back in the mailinglist archives, so: can I put 
> multiple clang plug-ins into a single shared library? I tried to do 
> that, but when I run it with:
>   clang -cc1 -load libA.dylib -plugin B -plugin C test.cpp
> 
> .. then only the C plug-in (the last -plugin) is run. If this is not 
> possible (yet?), is there another way to register multiple 
> ASTConsumer/RecursiveASTVisitor classes from a PluginASTAction?
> 
> -- Erik.
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev





More information about the cfe-dev mailing list