forked from kontalk/desktopclient-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
110 lines (89 loc) · 3.91 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
apply plugin: 'application'
apply plugin: 'java'
sourceCompatibility = '1.8'
targetCompatibility = '1.8'
mainClassName = 'org.kontalk.Kontalk'
ext.clientCommonDir = 'client-common-java'
applicationDefaultJvmArgs = ['''-Djava.util.logging.SimpleFormatter.format=%1$tH:%1$tM:%1$tS|%4$-6s|%2$s-%5$s%6$s%n''']
if (!file('./'+clientCommonDir+'/build.gradle').exists()) {
throw new GradleException('Submodule not found. Run "git submodule update --init".')
}
gradle.projectsEvaluated {
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
}
evaluationDependsOn ':'+clientCommonDir
ext.bcVersion = '1.60'
ext.smackVersion = project(':'+clientCommonDir).smackVersion
//configurations.all { transitive = false }
dependencies {
compile project(':'+clientCommonDir)
compile group: 'org.bouncycastle', name: 'bcpg-jdk15on', version: "$bcVersion"
compile group: 'org.bouncycastle', name: 'bcprov-jdk15on', version: "$bcVersion"
compile group: 'org.bouncycastle', name: 'bcpkix-jdk15on', version: "$bcVersion"
compile group: 'commons-cli', name: 'commons-cli', version: "1.3.1"
compile group: 'commons-codec', name: 'commons-codec', version: "1.10"
compile group: 'commons-configuration', name: 'commons-configuration', version: "1.10"
compile group: 'commons-io', name: 'commons-io', version: "2.4"
compile group: 'commons-lang', name: 'commons-lang', version: "2.6"
compile group: 'commons-logging', name: 'commons-logging', version: "1.1.3"
compile group: 'org.apache.httpcomponents', name: 'httpclient', version: "4.5.6"
compile group: 'org.apache.httpcomponents', name: 'httpcore', version: "4.4.10"
compile group: 'org.apache.tika', name: 'tika-core', version: "1.18"
compile group: 'org.jcraft', name: 'jorbis', version: "0.0.17"
//compile group: 'org.jxmpp', name: 'jxmpp-core', version: "0.4.2"
//compile group: 'org.jxmpp', name: 'jxmpp-util-cache', version: "0.4.2"
compile group: 'org.jxmpp', name: 'jxmpp-jid', version: "0.4.2"
compile group: 'net.sf.kxml', name: 'kxml2', version: "2.3.0"
// missing <scope> for junit in json-simple's pom
compile group: 'com.googlecode.json-simple', name: 'json-simple', version: "1.1.1", transitive: false
compile group: 'com.googlecode.libphonenumber', name: 'libphonenumber', version: "7.0.8"
compile group: 'org.ocpsoft.prettytime', name: 'prettytime', version: "3.2.7.Final"
compile group: 'org.igniterealtime.smack', name: 'smack-core', version: "$smackVersion"
compile group: 'org.igniterealtime.smack', name: 'smack-extensions', version: "$smackVersion"
compile group: 'org.igniterealtime.smack', name: 'smack-im', version: "$smackVersion"
compile group: 'org.igniterealtime.smack', name: 'smack-java7', version: "$smackVersion"
compile group: 'org.igniterealtime.smack', name: 'smack-tcp', version: "$smackVersion"
compile group: 'org.xerial', name: 'sqlite-jdbc', version: "3.23.1"
compile group: 'de.sciss', name: 'weblaf', version: "1.28"
testCompile group: 'junit', name: 'junit', version: "4.12"
}
repositories {
mavenCentral()
}
run {
if (project.hasProperty('jvmargs')) {
jvmArgs(jvmargs.split(','))
}
}
task deleteDeps(type: Delete) {
delete fileTree(project.file('dist/lib')) {
include '*.jar'
}
}
task copyDeps(type: Copy) {
from(configurations.runtime)
into project.file('dist/lib')
dependsOn ':deleteDeps'
}
jar {
baseName = 'KontalkDesktopApp'
destinationDir project.file('dist')
manifest {
attributes(
"Main-Class": mainClassName,
"Class-Path": configurations.compile.collect { 'lib/'+it.getName() }.join(' ')
)
}
dependsOn ':copyDeps'
}
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'org.owasp:dependency-check-gradle:3.3.1'
}
}
apply plugin: 'org.owasp.dependencycheck'