-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathbuild.sbt
63 lines (57 loc) · 2.34 KB
/
build.sbt
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
55
56
57
58
59
60
61
62
63
lazy val leo = (project in file("."))
.settings(
name := "Leo III",
description := "A Higher-Order Theorem Prover.",
version := "1.7.17",
organization := "org.leo",
scalaVersion := "2.13.15",
licenses += "BSD-3-Clause" -> url("https://opensource.org/licenses/BSD-3-Clause"),
logLevel := Level.Warn,
Compile/mainClass := Some("leo.Main"),
assembly/mainClass := Some("leo.Main"),
assembly/assemblyJarName := "leo3.jar",
assembly/logLevel := Level.Error,
assembly/test := {},
scalacOptions ++= Seq(
"-deprecation",
"-feature",
),
// set stack size to 4m
javaOptions ++= Seq(
"-Xss4m",
"-Xms512m",
"-Xmx2g"
),
//resolvers += "Sonatype S01 OSS Snapshots" at "https://s01.oss.sonatype.org/content/repositories/snapshots",
libraryDependencies += "io.github.leoprover" %% "scala-tptp-parser" % "1.7.1",
libraryDependencies ++= Seq("org.scalatest" %% "scalatest" % "3.2.19" % "test"),
nativeImageOptions += s"-H:ReflectionConfigurationFiles=${target.value / "native-image-configs" / "reflect-config.json"}",
nativeImageOptions += s"-H:ConfigurationFileDirectories=${target.value / "native-image-configs" }",
nativeImageOptions +="-H:+JNI",
//nativeImageOptions +="--static",
//nativeImageOptions +="--libc=musl",
//nativeImageOptions +="-H:CCompilerPath=/home/lex/dev/casc/x86_64-linux-musl-native/bin/x86_64-linux-musl-gcc",
//nativeImageOptions +="-H:UseMuslC=/home/lex/dev/casc/x86_64-linux-musl-native",
Test/parallelExecution := false,
).enablePlugins(NativeImagePlugin)
// The following are new commands to allow build with debug output
lazy val elideLevel = settingKey[Int]("elide code below this level.")
Global/elideLevel := 501
scalacOptions ++= Seq("-Xelide-below", elideLevel.value.toString)
def compileCommand(name: String, level: Int) =
Command.command(s"${name}Compile") { s =>
s"set elideLevel in Global := $level" ::
"compile" ::
s"set elideLevel in Global := 501" ::
s
}
commands += compileCommand("debug", 0)
def assemblyCommand(name: String, level: Int) =
Command.command(s"${name}Assembly") { s =>
s"set elideLevel in Global := $level" ::
"assembly" ::
s"set elideLevel in Global := 501" ::
s
}
commands += assemblyCommand("debug", 0)
//commands += compileCommand("prod", 1000)