-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathusvm.kotlin-conventions.gradle.kts
More file actions
53 lines (43 loc) · 1.38 KB
/
usvm.kotlin-conventions.gradle.kts
File metadata and controls
53 lines (43 loc) · 1.38 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
import org.gradle.api.tasks.testing.logging.TestExceptionFormat
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
kotlin("jvm")
`java-library`
}
group = "org.usvm"
repositories {
mavenCentral()
maven("https://jitpack.io")
}
dependencies {
// Align versions of all Kotlin components
implementation(platform("org.jetbrains.kotlin:kotlin-bom"))
implementation(kotlin("stdlib-jdk8"))
implementation(kotlin("reflect"))
implementation("com.microsoft.onnxruntime", "onnxruntime", Versions.onnxruntime)
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:${Versions.coroutines}")
testImplementation(kotlin("test"))
}
tasks {
withType<JavaCompile> {
sourceCompatibility = JavaVersion.VERSION_1_8.toString()
targetCompatibility = JavaVersion.VERSION_1_8.toString()
options.encoding = "UTF-8"
options.compilerArgs = options.compilerArgs + "-Xlint:all" + "-Werror"
}
withType<KotlinCompile> {
kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8.toString()
freeCompilerArgs = freeCompilerArgs + "-Xallow-result-return-type" + "-Xsam-conversions=class"
allWarningsAsErrors = true
}
}
}
tasks.named<Test>("test") {
// Use JUnit Platform for unit tests.
useJUnitPlatform()
maxHeapSize = "1G"
testLogging {
events("passed")
}
}