Permalink
Find file Copy path
fc849fd Dec 16, 2018
2 contributors

Users who have contributed to this file

@JonathanGiles @shemnon
68 lines (56 sloc) 1.68 KB
plugins {
id 'application'
id 'org.openjfx.javafxplugin' version '0.0.5'
id 'org.beryx.jlink' version '2.2.1'
}
mainClassName = "org.scenicview.scenicview/org.scenicview.ScenicView"
group = 'org.scenic-view'
version = '11.0.1'
defaultTasks 'install'
sourceCompatibility = '1.9'
targetCompatibility = '1.9'
repositories {
mavenCentral()
}
configurations {
jdk
binTray
}
sourceSets {
main {
compileClasspath += configurations.jdk
}
}
javafx {
modules = ['javafx.web', 'javafx.fxml', 'javafx.swing']
}
jar {
manifest {
attributes(
'Main-Class': 'org.scenicview.ScenicView', /* Used for standalone Scenic View */
'Agent-Class': 'org.fxconnector.remote.RuntimeAttach',/* But the standalone Scenic View starts up this agent when in runtime attach mode */
'Premain-Class': 'org.scenicview.ScenicView', /* Alternatively, this will be called if Scenic View is started as an agent */
'Automatic-Module-Name': 'org.scenicview.scenicview'
)
}
archiveName = 'scenicview.jar'
}
artifacts {
archives(jar)
}
ext.platform = osdetector.os == 'osx' ? 'mac' : osdetector.os == 'windows' ? 'win' : osdetector.os
jlink {
options = ['--strip-debug', '--compress', '2', '--no-header-files', '--no-man-pages']
launcher {
name = 'scenicView'
}
imageDir = file("${buildDir}/scenicview")
imageZip = file("${buildDir}/dist/scenicview-${platform}.zip")
}
tasks.jlink.doLast {
// Copy scenicView.jar to lib, it is required as loading Agent
copy {
from "${buildDir}/libs/scenicview.jar"
into "${buildDir}/scenicview/lib"
}
}