-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle
78 lines (67 loc) · 1.51 KB
/
build.gradle
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
plugins {
id 'java'
id 'jvm-test-suite'
id 'com.github.johnrengelman.shadow' version '8.1.1'
}
group = 'org.perlonjava'
version = '1.0-SNAPSHOT'
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
repositories {
mavenCentral()
}
dependencies {
implementation 'org.ow2.asm:asm:9.7'
implementation 'org.ow2.asm:asm-util:9.7'
implementation 'com.ibm.icu:icu4j:71.1'
implementation 'com.alibaba.fastjson2:fastjson2:2.0.53'
}
testing {
suites {
test {
useJUnitJupiter('5.9.2')
}
}
}
tasks.withType(JavaCompile).configureEach {
options.compilerArgs << '-Xlint:-options'
options.compilerArgs << '-Xlint:deprecation'
}
shadowJar {
archiveClassifier.set('')
destinationDirectory = file("$buildDir/../target")
manifest {
attributes 'Main-Class': 'org.perlonjava.Main'
}
exclude 'module-info.class'
exclude 'META-INF/MANIFEST.MF'
}
tasks.named('build') {
dependsOn shadowJar
}
sourceSets {
main {
resources {
srcDir 'src/main/perl'
include '**/*.pm'
}
}
test {
resources {
srcDir 'src/test/resources'
}
}
}
tasks.named('processResources', Copy) {
from(sourceSets.main.resources.srcDirs) {
include '**/*.pm'
}
into("$buildDir/resources/main")
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}
tasks.named('processTestResources', Copy) {
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}