mirror of https://github.com/sbt/sbt.git
Upgrade to latest zinc
This commit is contained in:
parent
893267785f
commit
c70c9989e5
|
|
@ -154,7 +154,7 @@ lazy val actionsProj = (project in mainPath / "actions").
|
|||
testedBaseSettings,
|
||||
name := "Actions",
|
||||
libraryDependencies ++= Seq(compilerClasspath, utilCompletion, compilerApiInfo,
|
||||
incrementalcompiler, compilerIvyIntegration, compilerInterface,
|
||||
zinc, compilerIvyIntegration, compilerInterface,
|
||||
sbtIO, utilLogging, utilRelation, libraryManagement, utilTracking)
|
||||
)
|
||||
|
||||
|
|
@ -184,7 +184,7 @@ lazy val mainProj = (project in mainPath).
|
|||
testedBaseSettings,
|
||||
name := "Main",
|
||||
libraryDependencies ++= scalaXml.value ++ Seq(launcherInterface, compilerInterface,
|
||||
sbtIO, utilLogging, utilLogic, libraryManagement, incrementalcompilerCompile)
|
||||
sbtIO, utilLogging, utilLogic, libraryManagement, zincCompile)
|
||||
)
|
||||
|
||||
// Strictly for bringing implicits and aliases from subsystems into the top-level sbt namespace through a single package object
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ object DotGraph {
|
|||
def apply(relations: Relations, outputDir: File, sourceToString: File => String, externalToString: File => String): Unit = {
|
||||
def file(name: String) = new File(outputDir, name)
|
||||
IO.createDirectory(outputDir)
|
||||
generateGraph(file("int-source-deps"), "dependencies", relations.internalSrcDep, sourceToString, sourceToString)
|
||||
generateGraph(file("int-source-deps"), "dependencies", relations.internalClassDep, identity[String], identity[String])
|
||||
generateGraph(file("binary-dependencies"), "externalDependencies", relations.binaryDep, externalToString, sourceToString)
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -273,7 +273,17 @@ object Tests {
|
|||
def discover(frameworks: Seq[Framework], analysis: CompileAnalysis, log: Logger): (Seq[TestDefinition], Set[String]) =
|
||||
discover(frameworks flatMap TestFramework.getFingerprints, allDefs(analysis), log)
|
||||
|
||||
def allDefs(analysis: CompileAnalysis) = analysis match { case analysis: Analysis => analysis.apis.internal.values.flatMap(_.api.definitions).toSeq }
|
||||
def allDefs(analysis: CompileAnalysis) = analysis match {
|
||||
case analysis: Analysis =>
|
||||
analysis.apis.internal.values.flatMap { ac =>
|
||||
val companions = ac.api
|
||||
val all =
|
||||
companions.classApi.structure.declared ++ companions.classApi.structure.inherited ++
|
||||
companions.objectApi.structure.declared ++ companions.objectApi.structure.inherited
|
||||
|
||||
all
|
||||
}.toSeq
|
||||
}
|
||||
def discover(fingerprints: Seq[Fingerprint], definitions: Seq[Definition], log: Logger): (Seq[TestDefinition], Set[String]) =
|
||||
{
|
||||
val subclasses = fingerprints collect { case sub: SubclassFingerprint => (sub.superclassName, sub.isModule, sub) };
|
||||
|
|
|
|||
|
|
@ -508,18 +508,18 @@ object Defaults extends BuildCommon {
|
|||
(cp, s) =>
|
||||
val ans: Seq[Analysis] = cp.flatMap(_.metadata get Keys.analysis) map { case a0: Analysis => a0 }
|
||||
val succeeded = TestStatus.read(succeededFile(s.cacheDirectory))
|
||||
val stamps = collection.mutable.Map.empty[File, Long]
|
||||
val stamps = collection.mutable.Map.empty[String, Long]
|
||||
def stamp(dep: String): Long = {
|
||||
val stamps = for (a <- ans; f <- a.relations.definesClass(dep)) yield intlStamp(f, a, Set.empty)
|
||||
val stamps = for (a <- ans) yield intlStamp(dep, a, Set.empty)
|
||||
if (stamps.isEmpty) Long.MinValue else stamps.max
|
||||
}
|
||||
def intlStamp(f: File, analysis: Analysis, s: Set[File]): Long = {
|
||||
if (s contains f) Long.MinValue else
|
||||
stamps.getOrElseUpdate(f, {
|
||||
def intlStamp(c: String, analysis: Analysis, s: Set[String]): Long = {
|
||||
if (s contains c) Long.MinValue else
|
||||
stamps.getOrElseUpdate(c, {
|
||||
import analysis.{ relations => rel, apis }
|
||||
rel.internalSrcDeps(f).map(intlStamp(_, analysis, s + f)) ++
|
||||
rel.externalDeps(f).map(stamp) +
|
||||
apis.internal(f).compilation.startTime
|
||||
rel.internalClassDeps(c).map(intlStamp(_, analysis, s + c)) ++
|
||||
rel.externalDeps(c).map(stamp) +
|
||||
apis.internal(c).compilation.startTime
|
||||
}.max)
|
||||
}
|
||||
def noSuccessYet(test: String) = succeeded.get(test) match {
|
||||
|
|
|
|||
|
|
@ -11,8 +11,8 @@ object Dependencies {
|
|||
// sbt modules
|
||||
val utilVersion = "0.1.0-M11"
|
||||
val ioVersion = "1.0.0-M3"
|
||||
val incrementalcompilerVersion = "0.1.0-M3"
|
||||
val librarymanagementVersion = "0.1.0-M7"
|
||||
val zincVersion = "0.1.0-M3-84942e08e7b11c6ef831c6443fc31bbff19ed3c2-SNAPSHOT"
|
||||
val librarymanagementVersion = "0.1.0-27bf18f7a3d945d84f72bb0e0e4aa98151417609-SNAPSHOT"
|
||||
lazy val sbtIO = "org.scala-sbt" %% "io" % ioVersion
|
||||
lazy val utilCollection = "org.scala-sbt" %% "util-collection" % utilVersion
|
||||
lazy val utilLogging = "org.scala-sbt" %% "util-logging" % utilVersion
|
||||
|
|
@ -30,13 +30,13 @@ object Dependencies {
|
|||
lazy val rawLauncher = "org.scala-sbt" % "launcher" % "1.0.0-M1"
|
||||
lazy val testInterface = "org.scala-sbt" % "test-interface" % "1.0"
|
||||
|
||||
lazy val incrementalcompiler = "org.scala-sbt" %% "incrementalcompiler" % incrementalcompilerVersion
|
||||
lazy val incrementalcompilerCompile = "org.scala-sbt" %% "incrementalcompiler-compile" % incrementalcompilerVersion
|
||||
lazy val compilerInterface = "org.scala-sbt" % "compiler-interface" % incrementalcompilerVersion
|
||||
lazy val compilerBrdige = "org.scala-sbt" %% "compiler-bridge" % incrementalcompilerVersion
|
||||
lazy val compilerClasspath = "org.scala-sbt" %% "incrementalcompiler-classpath" % incrementalcompilerVersion
|
||||
lazy val compilerApiInfo = "org.scala-sbt" %% "incrementalcompiler-apiinfo" % incrementalcompilerVersion
|
||||
lazy val compilerIvyIntegration = "org.scala-sbt" %% "incrementalcompiler-ivy-integration" % incrementalcompilerVersion
|
||||
lazy val zinc = "org.scala-sbt" %% "zinc" % zincVersion
|
||||
lazy val zincCompile = "org.scala-sbt" %% "zinc-compile" % zincVersion
|
||||
lazy val compilerInterface = "org.scala-sbt" % "compiler-interface" % zincVersion
|
||||
lazy val compilerBrdige = "org.scala-sbt" %% "compiler-bridge" % zincVersion
|
||||
lazy val compilerClasspath = "org.scala-sbt" %% "zinc-classpath" % zincVersion
|
||||
lazy val compilerApiInfo = "org.scala-sbt" %% "zinc-apiinfo" % zincVersion
|
||||
lazy val compilerIvyIntegration = "org.scala-sbt" %% "zinc-ivy-integration" % zincVersion
|
||||
|
||||
lazy val scalaCheck = "org.scalacheck" %% "scalacheck" % "1.11.4"
|
||||
lazy val specs2 = "org.specs2" %% "specs2" % "2.3.11"
|
||||
|
|
|
|||
Loading…
Reference in New Issue