Flip Gradle plugin kotlin_module names

Now common SourceSet output will have '_common' suffix, while all
variants will have the same name - '<module-name>.kotlin_module'.

This change is required for KSP as short-term workaround, as they
are using some internal properties/methods, which was mangled before
this change and hard to access in different variants.

^KT-52138 Fixed
This commit is contained in:
Yahor Berdnikau
2022-04-21 18:12:44 +02:00
committed by Space
parent 204bc4ca95
commit 5450367e39
2 changed files with 16 additions and 14 deletions
@@ -100,7 +100,7 @@ class UpToDateIT : KGPBaseTest() {
val originalPaths get() = originalCompilerCp.map { it.replace("\\", "/") }.joinToString(", ") { "'$it'" }
override fun initProject(project: TestProject) = with(project) {
val pluginSuffix = "kotlin_gradle_plugin"
val pluginSuffix = "kotlin_gradle_plugin_common"
buildGradle.appendText(
"\nafterEvaluate { println 'compiler_cp=' + compileKotlin.getDefaultCompilerClasspath\$$pluginSuffix().toList() }"
)