-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
93 lines (74 loc) · 2.62 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
//Note: this section 'buildscript` is only for the dependencies of the buildscript itself.
buildscript {
repositories {
mavenCentral()
}
}
plugins {
id "java-library"
id 'maven-publish'
id 'signing'
id 'com.palantir.git-version' version '0.11.0' //version helper
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(17)
}
withJavadocJar()
withSourcesJar()
}
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
options.compilerArgs = ['-proc:none', '-Xlint:all','-Werror','-Xdiags:verbose']
}
tasks.withType(Javadoc).configureEach {
options.addStringOption('encoding', 'UTF-8')
options.addStringOption('Xdoclint:none', '-quiet')
}
final isRelease = Boolean.getBoolean("release")
version = (isRelease ? gitVersion() : gitVersion() + "-SNAPSHOT").replaceAll(".dirty", "")
logger.info("build for version:" + version)
group = 'org.broadinstitute'
wrapper {
gradleVersion = '8.12.1'
}
publishing {
publications {
gatkNativeBindings(MavenPublication) {
from components.java
pom {
name ='gatk-native-bindings'
packaging ='jar'
description ='Bindings for native libraries to implement to be compatible with GATK4'
url = 'http://github.com/broadinstitute/gatk-native-bindings'
scm {
url = 'scm:git@github.com:broadinstitute/gatk-native-bindings.git'
connection = 'scm:git@github.com:broadinstitute/gatk-native-bindings.git'
developerConnection = 'scm:git@github.com:broadinstitute/gatk-native-bindings.git'
}
developers {
developer {
id = "gatkdev"
name = "GATK Development Team"
email = "gatk-dev-public@broadinstitute.org"
}
}
licenses {
license {
name ='BSD 3-Clause'
url = 'https://github.com/broadinstitute/gatk-native-bindings/blob/master/LICENSE.TXT'
distribution = 'repo'
}
}
}
}
}
/**
* Sign non-snapshot releases with our secret key. This should never need to be invoked directly.
*/
signing {
required = { isRelease && gradle.taskGraph.hasTask("publishGatkNativeBindingsPublicationToMavenRepository") }
sign publishing.publications.gatkNativeBindings
}
tasks.register('install') { dependsOn publishToMavenLocal }
}