@@ -381,6 +381,12 @@ object Build {
381381 dottyLib + File .pathSeparator + dottyInterfaces + File .pathSeparator + otherDeps
382382 }
383383
384+ lazy val semanticDBSettings = Seq (
385+ baseDirectory in (Compile , run) := baseDirectory.value / " .." ,
386+ baseDirectory in Test := baseDirectory.value / " .." ,
387+ libraryDependencies += " com.novocode" % " junit-interface" % " 0.11" % Test
388+ )
389+
384390 // Settings shared between dotty-doc and dotty-doc-bootstrapped
385391 lazy val dottyDocSettings = Seq (
386392 baseDirectory in (Compile , run) := baseDirectory.value / " .." ,
@@ -904,6 +910,8 @@ object Build {
904910 lazy val `dotty-bench` = project.in(file(" bench" )).asDottyBench(NonBootstrapped )
905911 lazy val `dotty-bench-bootstrapped` = project.in(file(" bench" )).asDottyBench(Bootstrapped )
906912
913+ lazy val `dotty-semantic-db` = project.in(file(" semantic-db" )).asDottySemanticDB(Bootstrapped )
914+
907915 // Depend on dotty-library so that sbt projects using dotty automatically
908916 // depend on the dotty-library
909917 lazy val `scala-library` = project.
@@ -1297,6 +1305,10 @@ object Build {
12971305 settings(commonBenchmarkSettings).
12981306 enablePlugins(JmhPlugin )
12991307
1308+ def asDottySemanticDB (implicit mode : Mode ): Project = project.withCommonSettings.
1309+ dependsOn(dottyCompiler).
1310+ settings(semanticDBSettings)
1311+
13001312 def asDist (implicit mode : Mode ): Project = project.
13011313 enablePlugins(PackPlugin ).
13021314 withCommonSettings.
0 commit comments