2018-08-24 14:51:40 +00:00
|
|
|
plugins {
|
|
|
|
id 'com.github.johnrengelman.shadow'
|
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
maven {
|
|
|
|
url "$artifactory_contextUrl/corda-dev"
|
2018-08-22 15:01:39 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-08-24 14:51:40 +00:00
|
|
|
configurations {
|
|
|
|
deterministicRt
|
2018-08-22 15:01:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
|
|
|
|
compile "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version"
|
|
|
|
compile "org.apache.logging.log4j:log4j-slf4j-impl:$log4j_version"
|
|
|
|
compile "com.jcabi:jcabi-manifests:$jcabi_manifests_version"
|
|
|
|
|
|
|
|
compile "info.picocli:picocli:$picocli_version"
|
|
|
|
compile project(path: ":djvm", configuration: "shadow")
|
|
|
|
|
2018-08-24 14:51:40 +00:00
|
|
|
// Deterministic runtime - used in whitelist generation
|
|
|
|
deterministicRt project(path: ':jdk8u-deterministic', configuration: 'jdk')
|
2018-08-22 15:01:39 +00:00
|
|
|
}
|
|
|
|
|
2018-08-24 14:51:40 +00:00
|
|
|
jar.enabled = false
|
|
|
|
|
|
|
|
shadowJar {
|
|
|
|
baseName = "corda-djvm"
|
|
|
|
classifier = 'cli'
|
2018-08-22 15:01:39 +00:00
|
|
|
manifest {
|
|
|
|
attributes(
|
2018-08-24 14:51:40 +00:00
|
|
|
'Automatic-Module-Name': 'net.corda.djvm',
|
|
|
|
'Main-Class': 'net.corda.djvm.tools.cli.Program',
|
|
|
|
'Build-Date': new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
|
2018-08-22 15:01:39 +00:00
|
|
|
)
|
|
|
|
}
|
|
|
|
}
|
2018-08-24 14:51:40 +00:00
|
|
|
assemble.dependsOn shadowJar
|
2018-08-22 15:01:39 +00:00
|
|
|
|
2018-08-24 14:51:40 +00:00
|
|
|
task generateWhitelist(type: JavaExec, dependsOn: shadowJar) {
|
|
|
|
// This is an example of how a whitelist can be generated from a JAR. In most applications though, it is recommended
|
|
|
|
// that the minimal set whitelist is used.
|
|
|
|
main = '-jar'
|
|
|
|
args = [shadowJar.outputs.files.singleFile, 'whitelist', 'generate', '-o', "$buildDir/jdk8-deterministic.dat.gz", configurations.deterministicRt.files[0] ]
|
2018-08-22 15:01:39 +00:00
|
|
|
}
|