-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
76 lines (66 loc) · 2.11 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
plugins {
id 'java'
id 'application'
id 'org.openjfx.javafxplugin' version '0.0.9'
id "org.beryx.jlink" version "2.23.7"
}
group 'org.example'
repositories {
mavenCentral()
jcenter()
}
dependencies {
implementation 'com.github.almasb:fxgl:11.15'
implementation('org.controlsfx:controlsfx:11.0.3') {
exclude group: 'org.openjfx'
}
}
test {
useJUnitPlatform()
}
javafx {
version = "16"
modules = [ 'javafx.controls', 'javafx.fxml', 'javafx.swing', 'javafx.media' ]
}
application {
mainClassName = "$moduleName/com.adrianghub.zombie.ZombieApp"
}
ext.os = org.gradle.internal.os.OperatingSystem.current()
jlink {
options = ['--strip-debug', '--compress', '2', '--no-header-files', '--no-man-pages']
launcher {
name = 'zombie-fxgl'
}
jpackage {
// Let the plugin detect the path to the JDK providing the jpackage tool by searching the locations indicated by:
// - the badass.jlink.jpackage.home system property
// - the BADASS_JLINK_JPACKAGE_HOME environment variable
// - the java.home system property
// - the JAVA_HOME environment variable
//
// OR
//
// explicitly configure the below property:
jpackageHome = 'C:/Program Files/Java/jdk-16.0.1'
//
// OR
//
// download and extract a JDK that contains the jpackage tool by setting the system property 'download.jpackage':
if(Boolean.getBoolean('download.jpackage')) {
jpackageHome = downloadJPackage()
}
if(os.macOsX) {
jvmArgs = ["-Duser.dir=/tmp"]
installerOptions = [
// '--mac-sign',
// '--mac-signing-key-user-name', System.getenv('SIGNING_KEY_USER_NAME'),
// '--mac-signing-keychain', System.getenv('SIGNING_KEYCHAIN_PATH')
]
} else if(os.windows) {
installerOptions = ['--win-per-user-install', '--win-dir-chooser', '--win-menu']
// } else {
// installerType = 'deb' // 'rpm'
}
installerOptions += '--verbose'
}
}