[JS IR] stdlib: switch between artifacts rather than artifact content
The switch `includeStdlibJsIr` now affects which artifact is published: the one with IR or the one without. Previously it affected whether or not IR was bundled into the artifact "with IR".
This commit is contained in:
@@ -59,11 +59,10 @@ task libraryJarWithIr(type: Zip, dependsOn: libraryJarWithoutIr) {
|
|||||||
duplicatesStrategy DuplicatesStrategy.FAIL
|
duplicatesStrategy DuplicatesStrategy.FAIL
|
||||||
|
|
||||||
from zipTree(libraryJarWithoutIr.archiveFile)
|
from zipTree(libraryJarWithoutIr.archiveFile)
|
||||||
if (rootProject.includeStdlibJsIr) {
|
|
||||||
def irKlib = tasks.getByPath(":kotlin-stdlib-js-ir:generateKotlinTestKLib")
|
def irKlib = tasks.getByPath(":kotlin-stdlib-js-ir:generateKotlinTestKLib")
|
||||||
dependsOn(irKlib)
|
dependsOn(irKlib)
|
||||||
from fileTree("${irKlib.outputs.files.singleFile.path}/klib")
|
from fileTree("${irKlib.outputs.files.singleFile.path}/klib")
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
task sourcesJar(type: Jar, dependsOn: classes) {
|
task sourcesJar(type: Jar, dependsOn: classes) {
|
||||||
@@ -73,7 +72,7 @@ task sourcesJar(type: Jar, dependsOn: classes) {
|
|||||||
|
|
||||||
artifacts {
|
artifacts {
|
||||||
runtime libraryJarWithoutIr
|
runtime libraryJarWithoutIr
|
||||||
archives libraryJarWithIr
|
archives rootProject.includeStdlibJsIr ? libraryJarWithIr : libraryJarWithoutIr
|
||||||
distLibrary libraryJarWithoutIr
|
distLibrary libraryJarWithoutIr
|
||||||
archives sourcesJar
|
archives sourcesJar
|
||||||
sources sourcesJar
|
sources sourcesJar
|
||||||
|
|||||||
@@ -317,11 +317,10 @@ task libraryJarWithIr(type: Zip, dependsOn: libraryJarWithoutIr) {
|
|||||||
duplicatesStrategy DuplicatesStrategy.FAIL
|
duplicatesStrategy DuplicatesStrategy.FAIL
|
||||||
|
|
||||||
from zipTree(libraryJarWithoutIr.archiveFile)
|
from zipTree(libraryJarWithoutIr.archiveFile)
|
||||||
if (rootProject.includeStdlibJsIr) {
|
|
||||||
def irKlib = tasks.getByPath(":kotlin-stdlib-js-ir:generateFullRuntimeKLib")
|
def irKlib = tasks.getByPath(":kotlin-stdlib-js-ir:generateFullRuntimeKLib")
|
||||||
dependsOn(irKlib)
|
dependsOn(irKlib)
|
||||||
from fileTree("${irKlib.outputs.files.singleFile.path}/klib")
|
from fileTree("${irKlib.outputs.files.singleFile.path}/klib")
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -371,7 +370,7 @@ task distSourcesJar(type: Jar) {
|
|||||||
|
|
||||||
artifacts {
|
artifacts {
|
||||||
runtime libraryJarWithoutIr
|
runtime libraryJarWithoutIr
|
||||||
archives libraryJarWithIr
|
archives rootProject.includeStdlibJsIr ? libraryJarWithIr : libraryJarWithoutIr
|
||||||
archives sourcesJar
|
archives sourcesJar
|
||||||
sources sourcesJar
|
sources sourcesJar
|
||||||
distSources distSourcesJar
|
distSources distSourcesJar
|
||||||
|
|||||||
Reference in New Issue
Block a user