forked from grpc/grpc-java
-
Notifications
You must be signed in to change notification settings - Fork 3
/
build.gradle
79 lines (67 loc) · 2.07 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
// Add dependency on the protobuf plugin
buildscript {
repositories {
maven { // The google mirror is less flaky than mavenCentral()
url "https://maven-central.storage-download.googleapis.com/repos/central/data/" }
gradlePluginPortal()
}
dependencies {
classpath libraries.protobuf_plugin
classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.4'
}
}
apply plugin: 'com.github.johnrengelman.shadow'
description = "gRPC: XDS plugin"
[compileJava].each() {
it.options.compilerArgs += [
// valueOf(int) in RoutingPriority has been deprecated
"-Xlint:-deprecation",
]
}
dependencies {
compile project(':grpc-protobuf'),
project(':grpc-stub'),
project(':grpc-core')
compile (libraries.protobuf_util) {
// prefer 26.0-android from libraries instead of 20.0
exclude group: 'com.google.guava', module: 'guava'
// prefer 2.3.3 from libraries instead of 2.3.2
exclude group: 'com.google.errorprone', module: 'error_prone_annotations'
}
testCompile project(':grpc-core').sourceSets.test.output
compileOnly libraries.javax_annotation
testCompile project(':grpc-testing'),
libraries.guava_testlib
signature "org.codehaus.mojo.signature:java17:1.0@signature"
}
apply plugin: 'com.google.protobuf'
sourceSets {
main {
proto {
srcDir 'third_party/envoy/src/main/proto'
srcDir 'third_party/gogoproto/src/main/proto'
srcDir 'third_party/protoc-gen-validate/src/main/proto'
}
}
}
configureProtoCompilation()
jar {
classifier = 'original'
}
shadowJar {
classifier = null
dependencies {
include(project(':grpc-xds'))
}
relocate 'io.envoyproxy', 'io.grpc.xds.shaded.io.envoyproxy'
relocate 'validate', 'io.grpc.xds.shaded.com.lyft.pgv.validate'
exclude "**/*.proto"
}
publishing {
publications {
maven(MavenPublication) {
artifact shadowJar
artifacts.removeAll { it.classifier == 'original' }
}
}
}