Add dependency in disabled jar task on custom libraryJarWithIr
jar task is disabled, but its artifact is still used through the runtime configuration in the other projects. In fact, dependent projects get both libs/kotlin-stdlib-js-1.3-SNAPSHOT.jar lib/dist/kotlin-stdlib-js-1.3-SNAPSHOT.jar in their classpath. However the former artifact is built with libraryJarWithIr task after jar task is skipped. This leads to a situation during the parallel build that a dependent project tries to read that artifact when libraryJarWithIr task writes it. This commit adds a dependency edge between the disabled jar and custom libraryJarWithIr tasks, so that the artifact is ready by the moment jar task has finished.
This commit is contained in:
@@ -66,6 +66,8 @@ task libraryJarWithIr(type: Zip, dependsOn: libraryJarWithoutIr) {
|
||||
}
|
||||
}
|
||||
|
||||
jar.dependsOn(libraryJarWithIr)
|
||||
|
||||
task sourcesJar(type: Jar, dependsOn: classes) {
|
||||
classifier = 'sources'
|
||||
from (sourceSets.main.allSource)
|
||||
|
||||
@@ -323,6 +323,7 @@ task libraryJarWithIr(type: Zip, dependsOn: libraryJarWithoutIr) {
|
||||
}
|
||||
}
|
||||
|
||||
jar.dependsOn(libraryJarWithIr)
|
||||
|
||||
task sourcesJar(type: Jar, dependsOn: compileJs) {
|
||||
classifier = 'sources'
|
||||
|
||||
Reference in New Issue
Block a user