Merge pull request #4403 from eed3si9n/wip/boot-dependencyresolution

Fix resolver for compiler bridge
This commit is contained in:
eugene yokota 2018-10-05 13:05:02 -04:00 committed by GitHub
commit 9eb42e8768
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 2 deletions

View File

@ -88,3 +88,5 @@ object SlashSyntax {
final class RichScope(protected val scope: Scope) extends HasSlashKey
}
private[sbt] object SlashSyntax0 extends SlashSyntax

View File

@ -107,6 +107,7 @@ import sbt.internal.inc.{
MixedAnalyzingCompiler,
ScalaInstance
}
import sbt.SlashSyntax0._
object Defaults extends BuildCommon {
final val CacheDirectoryName = "cache"
@ -518,7 +519,7 @@ object Defaults extends BuildCommon {
globalLock = launcher.globalLock,
componentProvider = app.provider.components,
secondaryCacheDir = Option(zincDir),
dependencyResolution = dependencyResolution.value,
dependencyResolution = bootDependencyResolution.value,
compilerBridgeSource = scalaCompilerBridgeSource.value,
scalaJarsTarget = zincDir,
log = streams.value.log
@ -2361,7 +2362,10 @@ object Classpaths {
}
} tag (Tags.Update, Tags.Network)).value
)
) ++ Seq(bootIvyConfiguration := (ivyConfiguration in updateSbtClassifiers).value)
) ++ Seq(
bootIvyConfiguration := (updateSbtClassifiers / ivyConfiguration).value,
bootDependencyResolution := (updateSbtClassifiers / dependencyResolution).value
)
def classifiersModuleTask: Initialize[Task[GetClassifiersModule]] =
Def.task {

View File

@ -360,6 +360,7 @@ object Keys {
val ivyConfigurations = settingKey[Seq[Configuration]]("The defined configurations for dependency management. This may be different from the configurations for Project settings.").withRank(BSetting)
// This setting was created to work around the limitation of derived tasks not being able to use task-scoped task: ivyConfiguration in updateSbtClassifiers
val bootIvyConfiguration = taskKey[IvyConfiguration]("General dependency management (Ivy) settings, configured to retrieve sbt's components.").withRank(DTask)
val bootDependencyResolution = taskKey[DependencyResolution]("Dependency resolution to retrieve sbt's components.").withRank(CTask)
val moduleSettings = taskKey[ModuleSettings]("Module settings, which configure dependency management for a specific module, such as a project.").withRank(DTask)
val unmanagedBase = settingKey[File]("The default directory for manually managed libraries.").withRank(ASetting)
val updateConfiguration = settingKey[UpdateConfiguration]("Configuration for resolving and retrieving managed dependencies.").withRank(DSetting)