mirror of
https://github.com/corda/corda.git
synced 2025-01-20 03:36:29 +00:00
Modify how Gradle creates capsules: (#730)
- Better Gradle dependency management. - Remove empty module jars from the capsules.
This commit is contained in:
parent
36a091dd6a
commit
179eccdd20
@ -19,15 +19,12 @@ configurations {
|
|||||||
sourceCompatibility = 1.6
|
sourceCompatibility = 1.6
|
||||||
targetCompatibility = 1.6
|
targetCompatibility = 1.6
|
||||||
|
|
||||||
dependencies {
|
task buildCordaJAR(type: FatCapsule, dependsOn: project(':node').compileJava) {
|
||||||
compile project(':node')
|
|
||||||
}
|
|
||||||
|
|
||||||
task buildCordaJAR(type: FatCapsule) {
|
|
||||||
applicationClass 'net.corda.node.Corda'
|
applicationClass 'net.corda.node.Corda'
|
||||||
archiveName "corda-${corda_release_version}.jar"
|
archiveName "corda-${corda_release_version}.jar"
|
||||||
applicationSource = files(
|
applicationSource = files(
|
||||||
project.tasks.findByName('jar'),
|
project(':node').configurations.compile,
|
||||||
|
project(':node').jar,
|
||||||
'../build/classes/main/CordaCaplet.class',
|
'../build/classes/main/CordaCaplet.class',
|
||||||
'../build/classes/main/CordaCaplet$1.class',
|
'../build/classes/main/CordaCaplet$1.class',
|
||||||
"$rootDir/config/dev/log4j2.xml"
|
"$rootDir/config/dev/log4j2.xml"
|
||||||
|
@ -25,14 +25,14 @@ repositories {
|
|||||||
sourceCompatibility = 1.6
|
sourceCompatibility = 1.6
|
||||||
targetCompatibility = 1.6
|
targetCompatibility = 1.6
|
||||||
|
|
||||||
dependencies {
|
task buildExplorerJAR(type: FatCapsule, dependsOn: project(':tools:explorer').compileJava) {
|
||||||
compile project(':tools:explorer')
|
|
||||||
}
|
|
||||||
|
|
||||||
task buildExplorerJAR(type: FatCapsule) {
|
|
||||||
applicationClass 'net.corda.explorer.Main'
|
applicationClass 'net.corda.explorer.Main'
|
||||||
archiveName "node-explorer-${corda_release_version}.jar"
|
archiveName "node-explorer-${corda_release_version}.jar"
|
||||||
applicationSource = files(project.tasks.findByName('jar'), '../build/classes/main/ExplorerCaplet.class')
|
applicationSource = files(
|
||||||
|
project(':tools:explorer').configurations.compile,
|
||||||
|
project(':tools:explorer').jar,
|
||||||
|
'../build/classes/main/ExplorerCaplet.class'
|
||||||
|
)
|
||||||
classifier 'fat'
|
classifier 'fat'
|
||||||
|
|
||||||
capsuleManifest {
|
capsuleManifest {
|
||||||
|
@ -19,17 +19,14 @@ configurations {
|
|||||||
sourceCompatibility = 1.6
|
sourceCompatibility = 1.6
|
||||||
targetCompatibility = 1.6
|
targetCompatibility = 1.6
|
||||||
|
|
||||||
dependencies {
|
task buildWebserverJar(type: FatCapsule, dependsOn: project(':node').compileJava) {
|
||||||
compile project(':webserver')
|
|
||||||
}
|
|
||||||
|
|
||||||
task buildWebserverJar(type: FatCapsule) {
|
|
||||||
applicationClass 'net.corda.webserver.WebServer'
|
applicationClass 'net.corda.webserver.WebServer'
|
||||||
archiveName "corda-webserver-${corda_release_version}.jar"
|
archiveName "corda-webserver-${corda_release_version}.jar"
|
||||||
applicationSource = files(
|
applicationSource = files(
|
||||||
project.tasks.findByName('jar'),
|
project(':webserver').configurations.compile,
|
||||||
new File(project(':node').rootDir, 'node/build/classes/main/CordaCaplet.class'),
|
project(':webserver').jar,
|
||||||
new File(project(':node').rootDir, 'node/build/classes/main/CordaCaplet$1.class'),
|
new File(project(':node').buildDir, 'classes/main/CordaCaplet.class'),
|
||||||
|
new File(project(':node').buildDir, 'classes/main/CordaCaplet$1.class'),
|
||||||
"$rootDir/config/dev/log4j2.xml"
|
"$rootDir/config/dev/log4j2.xml"
|
||||||
)
|
)
|
||||||
from 'NOTICE' // Copy CDDL notice
|
from 'NOTICE' // Copy CDDL notice
|
||||||
|
Loading…
Reference in New Issue
Block a user