forked from RuedigerMoeller/fast-serialization
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
107 lines (87 loc) · 2.67 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
import java.util.zip.ZipFile
apply plugin: 'java'
apply plugin: 'maven'
version="2.44"
targetCompatibility = 1.7
sourceCompatibility = 1.7
compileJava.options.debugOptions.debugLevel = "source,lines,vars"
compileTestJava.options.debugOptions.debugLevel = "source,lines,vars"
jar.baseName='fst'
repositories {
mavenCentral()
}
dependencies {
compile fileTree("src/test/lib")
compile group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: '2.5.3'
compile group: 'org.javassist', name: 'javassist', version: '3.19.0-GA'
compile 'org.objenesis:objenesis:2.1'
}
task sourcesJar(type: Jar, dependsOn:classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
//task javadoc(type: Javadoc) {
// source = sourceSets.main.allJava
//}
task testJar(type: Jar, dependsOn:classes) {
classifier = 'bench_and_tests'
from 'src/test'
}
task allJar(type: Jar, dependsOn:jar) {
archiveName = 'fst-'+version+"-onejar.jar"
from zipTree('lib/objenesis-2.1.jar').matching { true }
from zipTree('lib/jackson-core-2.5.3.jar').matching { true }
from zipTree('lib/javassist-3.19.0-GA.jar').matching { true }
from zipTree('build/libs/fst-'+version+'.jar').matching { true }
}
task release(type: Jar, dependsOn:allJar) {
copy {
from configurations.compile.resolve()
into "lib"
exclude '**/fst*'
exclude '**/kryo*'
}
archiveName = 'fst-'+version+".zip"
into('src/main/java') {
from 'src/main/java'
}
into ('lib') {
from 'lib/jackson-core-2.5.3.jar'
from 'lib/objenesis-2.1.jar'
from 'lib/javassist-3.19.0-GA.jar'
from 'build/libs/fst-'+version+'.jar'
from 'build/libs/fst-'+version+'-onejar.jar'
}
}
compileJava {
targetCompatibility = 1.7
sourceCompatibility = 1.7
options.compilerArgs << '-XDignore.symbol.file'
options.compilerArgs << '-nowarn'
options.fork = true
options.forkOptions.executable = 'javac'
print options.compilerArgs
}
artifacts {
archives sourcesJar
}
//uploadArchives {
// repositories {
// mavenDeployer {
// repository(url: "http://org.apache.maven.wagon:wagon-http:2.2")
// pom.version = version
// pom.groupId = 'de.nustaq'
// pom.artifactId = 'fast-serialization'
// pom.project {
// dependencies { }
// description "fast and efficient java serialization drop-in replacement"
// licenses {
// license {
// name 'LGPL 2.1'
// distribution 'repo'
// }
// }
// }
// }
// }
//}