Drop useless :commonDistRuntime Gradle task

Reasons:
1. This task does not depend on anything. So, Gradle typically runs it somewhere in the very beginning of the build when the artifacts that this task is supposed to copy are not yet built.
2. This task is always used in conjunction with ":${target}CrossDistRuntime", which has all the necessary dependencies and does everything what :commonDistRuntime is supposed to do plus some additional work.
This commit is contained in:
Dmitriy Dolovov
2020-04-03 18:17:44 +07:00
committed by Dmitriy Dolovov
parent f8073eaded
commit 2f32d37840
4 changed files with 9 additions and 22 deletions
+1 -13
View File
@@ -412,7 +412,6 @@ task listDist(type: Exec) {
task distRuntime(type: Copy) {
dependsOn "${hostName}CrossDistRuntime"
dependsOn('commonDistRuntime')
}
task distEndorsedLibraries {
@@ -436,19 +435,8 @@ def stdlibDefaultComponent = "$stdlib/default"
def endorsedLibs = 'klib/common/endorsedLibraries'
def endorsedLibsBase = 'klib/common'
task commonDistRuntime(type: Copy) {
destinationDir distDir
// Target independant common part.
from(project(':runtime').file("build/${hostName}Stdlib")) {
include('**')
into(stdlib)
}
}
task crossDistRuntime(type: Copy) {
dependsOn.addAll(targetList.collect { "${it}CrossDistRuntime" })
dependsOn('commonDistRuntime')
}
task crossDistEndorsedLibraries(type: Copy) {
@@ -514,7 +502,7 @@ targetList.each { target ->
}
task("${target}CrossDist") {
dependsOn "${target}CrossDistRuntime", "distCompiler", "commonDistRuntime", "${target}CrossDistEndorsedLibraries"
dependsOn "${target}CrossDistRuntime", "distCompiler", "${target}CrossDistEndorsedLibraries"
if (target in cacheableTargetNames) {
dependsOn "${target}StdlibCache", "${target}EndorsedCache"
}