[JS IR] Add per-module output module name
This commit is contained in:
committed by
TeamCityServer
parent
4d7f7fc50f
commit
228c6879f5
+2
@@ -24,5 +24,7 @@ internal const val PRODUCE_ZIPPED_KLIB = "-Xir-produce-klib-file"
|
||||
|
||||
internal const val MODULE_NAME = "-Xir-module-name"
|
||||
|
||||
internal const val PER_MODULE_OUTPUT_NAME = "-Xir-per-module-output-name"
|
||||
|
||||
fun KotlinJsOptions.isProduceUnzippedKlib() = PRODUCE_UNZIPPED_KLIB in freeCompilerArgs
|
||||
fun KotlinJsOptions.isProduceZippedKlib() = PRODUCE_ZIPPED_KLIB in freeCompilerArgs
|
||||
+7
@@ -58,6 +58,13 @@ abstract class KotlinJsIrSubTarget(
|
||||
internal fun configure() {
|
||||
NpmResolverPlugin.apply(project)
|
||||
|
||||
target.compilations.all {
|
||||
val npmProject = it.npmProject
|
||||
it.kotlinOptions {
|
||||
freeCompilerArgs += "$PER_MODULE_OUTPUT_NAME=${npmProject.name}"
|
||||
}
|
||||
}
|
||||
|
||||
configureTests()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user