-
Notifications
You must be signed in to change notification settings - Fork 72
Compiler plugins in stubsAndApt compilation step (KAPT) #266
-
Hey,
First of all thanks for a great library :-)
I noticed that KotlinCompilation::stubsAndApt
uses a list of compiler plugins that is passed to KotlinCompilation::<init>
.
In some cases it might not be an expected behaviour. For example, if we're using jvm-abi-gen
compiler plugin to generate target's ABI.
In this example jvm-abi-gen
will work in the first Kotlinc KAPT incovation (1st and 2nd round) and in the second one (3rd round).
I think KotlinCompilation
needs a finer option tuning in this case.
Can you suggest the optimal way to implement it, please? I'm up to contribute the change, but need some guidance.
Thanks,
Sergei
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 1 comment
-
Am I understanding correctly that you want to use different compiler plugins in the first+second compilation step (aptAndStubs) and the third compilation step (compileKotlin)? I don't think it is possible to do this at the moment. I think the path of least resistance would be to simply add two new properties to the KotlinCompilation
class, something like kaptOnlyCompilerPlugins
(feel free to come up with better names) and simply append them to the list of plugins at the appropriate step.
Can you explain what exactly the use case is for this feature? I'm not familiar with the jvm-abi-gen plugin.
Beta Was this translation helpful? Give feedback.