-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sbt
More file actions
executable file
·54 lines (45 loc) · 1.66 KB
/
build.sbt
File metadata and controls
executable file
·54 lines (45 loc) · 1.66 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import java.io.PrintWriter
organization := "org.change"
version := "0.2.1-SNAPSHOT"
scalaVersion := "2.10.2"
name := "symnet"
scalacOptions := Seq("-unchecked", "-deprecation", "-encoding", "utf8")
fork := true
resolvers += "Sonatype OSS Snapshots" at
"https://oss.sonatype.org/content/repositories/releases"
libraryDependencies ++= {
Seq(
"org.antlr" % "antlr4" % "4.7",
"org.scalatest" %% "scalatest" % "3.0.5" % "test",
"junit" % "junit" % "4.12"
)
}
testFrameworks += new TestFramework("org.scalameter.ScalaMeterFramework")
parallelExecution in Test := false
exportJars := true
unmanagedJars in Compile += file("lib/z3/com.microsoft.z3.jar")
unmanagedResourceDirectories in Compile += baseDirectory.value / "lib" / "z3"
includeFilter in(Compile, unmanagedResourceDirectories) := ".dll,.so"
fork in Test := true
javaOptions in Test += "-Xss128M"
javaOptions in Test += "-Xmx32G"
javaOptions in run += "-Xss128M"
val MkUnixlauncher = config("mkunixlauncher") extend Compile
val mkunixlauncher = taskKey[Unit]("mkunixlauncher")
mkunixlauncher <<= (target, fullClasspath in Runtime) map { (target, cp) =>
def writeFile(file: File, str: String) {
val writer = new PrintWriter(file)
writer.println(str)
writer.close()
}
val cpString = cp.map(_.data).mkString(System.getProperty("path.separator"))
System.out.println(cpString)
val runtime_entrypoint = "org.change.p4.tools.Vera"
val launchString = """
CLASSPATH="%s"
java -Djava.class.path="${CLASSPATH}" %s "$@"
""".format(cpString, runtime_entrypoint)
val targetFile = (target / "vera.sh").asFile
writeFile(targetFile, launchString)
targetFile.setExecutable(true)
}