sbt checks and filters managed dependencies on Scala libraries, such as scala-library.jar and scala-compiler.jar. This page explains the details of this behavior.
sbt checks that the revisions of any explicit dependencies on Scala libraries match that of the scala.version declared for the project. For example, sbt would generate an error if you defined scala.version to be 2.7.2 but had the following in your project definition:val scalaSwing = "org.scala-lang" % "scala-swing" % "2.7.3"
To disable this check, set:
override def checkExplicitScalaDependencies = true
sbt excludes all dependencies on scala-library.jar and scala-compiler.jar so that these will not be downloaded. sbt does this because it already provides the right versions of scala-library.jar and scala-compiler.jar required for normal use. In particular,
If you need to explicitly reference the Scala jars used by sbt, see the Access to Scala Jars and Dependencies section below.
sbt can be configured to skip these checks in certain cases, but this should be considered atypical. If you want to do this anyway, you should define a non-standard configuration and exclude it from the configurations on which sbt performs checks and filtering:
val other = config("scalac-2.7.3") override def checkScalaInConfigurations = super.checkScalaInConfigurations - other val scalac2_7_3 = "org.scala-lang" % "scala-compiler" % "2.7.3" % "scalac-2.7.3"
You might use this to call java using the classpath given by managedClasspath("scalac-2.7.3"), for example.
To completely disable all filtering of dependencies, set
override def filterScalaJars = false