13
13
# limitations under the License.
14
14
15
15
16
- load ("@bazel_tools//tools/build_defs/repo:http.bzl" , "http_archive" )
17
-
18
16
#############################
19
17
# Load nested repository
20
18
#############################
@@ -27,129 +25,19 @@ local_repository(
27
25
)
28
26
29
27
#############################
30
- # Load Bazel Skylib rules
28
+ # Load Android Sdk
31
29
#############################
32
30
33
- BAZEL_SKYLIB_VERSION = "1.5.0"
34
-
35
- BAZEL_SKYLIB_SHA = "cd55a062e763b9349921f0f5db8c3933288dc8ba4f76dd9416aac68acee3cb94"
36
-
37
- http_archive (
38
- name = "bazel_skylib" ,
39
- sha256 = BAZEL_SKYLIB_SHA ,
40
- urls = [
41
- "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/%s/bazel-skylib-%s.tar.gz" % (BAZEL_SKYLIB_VERSION , BAZEL_SKYLIB_VERSION ),
42
- "https://github.com/bazelbuild/bazel-skylib/releases/download/%s/bazel-skylib-%s.tar.gz" % (BAZEL_SKYLIB_VERSION , BAZEL_SKYLIB_VERSION ),
43
- ],
44
- )
45
-
46
- load ("@bazel_skylib//:workspace.bzl" , "bazel_skylib_workspace" )
47
-
48
- bazel_skylib_workspace ()
49
-
50
- #############################
51
- # Load rules_java repository
52
- #############################
53
-
54
- http_archive (
55
- name = "rules_java" ,
56
- sha256 = "c73336802d0b4882e40770666ad055212df4ea62cfa6edf9cb0f9d29828a0934" ,
57
- url = "https://github.com/bazelbuild/rules_java/releases/download/5.3.5/rules_java-5.3.5.tar.gz" ,
58
- )
59
-
60
- ####################################################
61
- # Load Protobuf repository (needed by bazel-common)
62
- ####################################################
63
-
64
- http_archive (
65
- name = "rules_proto" ,
66
- # output from `sha256sum` on the downloaded tar.gz file
67
- sha256 = "66bfdf8782796239d3875d37e7de19b1d94301e8972b3cbd2446b332429b4df1" ,
68
- strip_prefix = "rules_proto-4.0.0" ,
69
- urls = [
70
- "https://mirror.bazel.build/github.com/bazelbuild/rules_proto/archive/refs/tags/4.0.0.tar.gz" ,
71
- "https://github.com/bazelbuild/rules_proto/archive/refs/tags/4.0.0.tar.gz" ,
72
- ],
73
- )
74
-
75
- load ("@rules_proto//proto:repositories.bzl" , "rules_proto_dependencies" , "rules_proto_toolchains" )
76
-
77
- rules_proto_dependencies ()
78
-
79
- rules_proto_toolchains ()
80
-
81
- #############################
82
- # Load Bazel-Common repository
83
- #############################
84
-
85
- http_archive (
86
- name = "google_bazel_common" ,
87
- sha256 = "82a49fb27c01ad184db948747733159022f9464fc2e62da996fa700594d9ea42" ,
88
- strip_prefix = "bazel-common-2a6b6406e12208e02b2060df0631fb30919080f3" ,
89
- urls = ["https://github.com/google/bazel-common/archive/2a6b6406e12208e02b2060df0631fb30919080f3.zip" ],
90
- )
91
-
92
- load ("@google_bazel_common//:workspace_defs.bzl" , "google_common_workspace_rules" )
93
-
94
- google_common_workspace_rules ()
95
-
96
- #############################
97
- # Load Protobuf dependencies
98
- #############################
99
-
100
- # rules_python and zlib are required by protobuf.
101
- # TODO(ronshapiro): Figure out if zlib is in fact necessary, or if proto can depend on the
102
- # @bazel_tools library directly. See discussion in
103
- # https://github.com/protocolbuffers/protobuf/pull/5389#issuecomment-481785716
104
- # TODO(cpovirk): Should we eventually get rules_python from "Bazel Federation?"
105
- # https://github.com/bazelbuild/rules_python#getting-started
106
-
107
- http_archive (
108
- name = "rules_python" ,
109
- sha256 = "e5470e92a18aa51830db99a4d9c492cc613761d5bdb7131c04bd92b9834380f6" ,
110
- strip_prefix = "rules_python-4b84ad270387a7c439ebdccfd530e2339601ef27" ,
111
- urls = ["https://github.com/bazelbuild/rules_python/archive/4b84ad270387a7c439ebdccfd530e2339601ef27.tar.gz" ],
112
- )
113
-
114
- http_archive (
115
- name = "zlib" ,
116
- build_file = "@com_google_protobuf//:third_party/zlib.BUILD" ,
117
- sha256 = "629380c90a77b964d896ed37163f5c3a34f6e6d897311f1df2a7016355c45eff" ,
118
- strip_prefix = "zlib-1.2.11" ,
119
- urls = ["https://github.com/madler/zlib/archive/v1.2.11.tar.gz" ],
31
+ android_sdk_repository (
32
+ name = "androidsdk" ,
33
+ api_level = 32 ,
34
+ build_tools_version = "32.0.0" ,
120
35
)
121
36
122
- #############################
123
- # Load Robolectric repository
124
- #############################
125
-
126
- ROBOLECTRIC_VERSION = "4.4"
127
-
128
- http_archive (
129
- name = "robolectric" ,
130
- sha256 = "d4f2eb078a51f4e534ebf5e18b6cd4646d05eae9b362ac40b93831bdf46112c7" ,
131
- strip_prefix = "robolectric-bazel-%s" % ROBOLECTRIC_VERSION ,
132
- urls = ["https://github.com/robolectric/robolectric-bazel/archive/%s.tar.gz" % ROBOLECTRIC_VERSION ],
133
- )
134
-
135
- load ("@robolectric//bazel:robolectric.bzl" , "robolectric_repositories" )
136
-
137
- robolectric_repositories ()
138
-
139
37
#############################
140
38
# Load Kotlin repository
141
39
#############################
142
40
143
- RULES_KOTLIN_TAG = "v1.8"
144
-
145
- RULES_KOTLIN_SHA = "01293740a16e474669aba5b5a1fe3d368de5832442f164e4fbfc566815a8bc3a"
146
-
147
- http_archive (
148
- name = "io_bazel_rules_kotlin" ,
149
- sha256 = RULES_KOTLIN_SHA ,
150
- urls = ["https://github.com/bazelbuild/rules_kotlin/releases/download/%s/rules_kotlin_release.tgz" % RULES_KOTLIN_TAG ],
151
- )
152
-
153
41
load ("@io_bazel_rules_kotlin//kotlin:repositories.bzl" , "kotlin_repositories" , "kotlinc_version" )
154
42
155
43
KOTLIN_VERSION = "1.9.23"
@@ -172,23 +60,24 @@ kt_register_toolchains()
172
60
# Load Maven dependencies
173
61
#############################
174
62
175
- RULES_JVM_EXTERNAL_TAG = "4.5"
176
-
177
- RULES_JVM_EXTERNAL_SHA = "b17d7388feb9bfa7f2fa09031b32707df529f26c91ab9e5d909eb1676badd9a6"
178
-
179
- http_archive (
180
- name = "rules_jvm_external" ,
181
- sha256 = RULES_JVM_EXTERNAL_SHA ,
182
- strip_prefix = "rules_jvm_external-%s" % RULES_JVM_EXTERNAL_TAG ,
183
- url = "https://github.com/bazelbuild/rules_jvm_external/archive/%s.zip" % RULES_JVM_EXTERNAL_TAG ,
184
- )
185
-
186
63
load ("@rules_jvm_external//:defs.bzl" , "maven_install" )
187
64
188
65
ANDROID_LINT_VERSION = "30.1.0"
189
66
67
+ ANT_VERSION = "1.9.6"
68
+
69
+ ASM_VERSION = "9.6"
70
+
190
71
AUTO_COMMON_VERSION = "1.2.1"
191
72
73
+ BYTE_BUDDY_VERSION = "1.9.10"
74
+
75
+ CHECKER_FRAMEWORK_VERSION = "2.5.3"
76
+
77
+ ECLIPSE_SISU_VERSION = "0.3.0"
78
+
79
+ ERROR_PRONE_VERSION = "2.14.0"
80
+
192
81
# NOTE(bcorso): Even though we set the version here, our Guava version in
193
82
# processor code will use whatever version is built into JavaBuilder, which is
194
83
# tied to the version of Bazel we're using.
@@ -198,14 +87,10 @@ GRPC_VERSION = "1.2.0"
198
87
199
88
INCAP_VERSION = "0.2"
200
89
201
- BYTE_BUDDY_VERSION = "1.9.10"
202
-
203
- CHECKER_FRAMEWORK_VERSION = "2.5.3"
204
-
205
- ERROR_PRONE_VERSION = "2.14.0"
206
-
207
90
KSP_VERSION = KOTLIN_VERSION + "-1.0.19"
208
91
92
+ MAVEN_VERSION = "3.3.3"
93
+
209
94
maven_install (
210
95
artifacts = [
211
96
"androidx.annotation:annotation:1.1.0" ,
@@ -264,16 +149,27 @@ maven_install(
264
149
"io.grpc:grpc-protobuf:%s" % GRPC_VERSION ,
265
150
"jakarta.inject:jakarta.inject-api:2.0.1" ,
266
151
"javax.annotation:javax.annotation-api:1.3.2" ,
152
+ "javax.enterprise:cdi-api:1.0" ,
267
153
"javax.inject:javax.inject:1" ,
268
154
"javax.inject:javax.inject-tck:1" ,
269
155
"junit:junit:4.13" ,
270
156
"net.bytebuddy:byte-buddy:%s" % BYTE_BUDDY_VERSION ,
271
157
"net.bytebuddy:byte-buddy-agent:%s" % BYTE_BUDDY_VERSION ,
272
158
"net.ltgt.gradle.incap:incap:%s" % INCAP_VERSION ,
273
159
"net.ltgt.gradle.incap:incap-processor:%s" % INCAP_VERSION ,
160
+ "org.apache.ant:ant:%s" % ANT_VERSION ,
161
+ "org.apache.ant:ant-launcher:%s" % ANT_VERSION ,
162
+ "org.apache.maven:maven-artifact:%s" % MAVEN_VERSION ,
163
+ "org.apache.maven:maven-model:%s" % MAVEN_VERSION ,
164
+ "org.apache.maven:maven-plugin-api:%s" % MAVEN_VERSION ,
274
165
"org.checkerframework:checker-compat-qual:%s" % CHECKER_FRAMEWORK_VERSION ,
275
166
"org.checkerframework:dataflow:%s" % CHECKER_FRAMEWORK_VERSION ,
276
167
"org.checkerframework:javacutil:%s" % CHECKER_FRAMEWORK_VERSION ,
168
+ "org.codehaus.plexus:plexus-utils:3.0.20" ,
169
+ "org.codehaus.plexus:plexus-classworlds:2.5.2" ,
170
+ "org.codehaus.plexus:plexus-component-annotations:1.5.5" ,
171
+ "org.eclipse.sisu:org.eclipse.sisu.plexus:%s" % ECLIPSE_SISU_VERSION ,
172
+ "org.eclipse.sisu:org.eclipse.sisu.inject:%s" % ECLIPSE_SISU_VERSION ,
277
173
"org.hamcrest:hamcrest-core:1.3" ,
278
174
"org.jetbrains.kotlin:kotlin-annotation-processing-embeddable:%s" % KOTLIN_VERSION ,
279
175
"org.jetbrains.kotlin:kotlin-compiler-embeddable:%s" % KOTLIN_VERSION ,
@@ -282,7 +178,11 @@ maven_install(
282
178
"org.jetbrains.kotlinx:kotlinx-metadata-jvm:0.6.2" ,
283
179
"org.jspecify:jspecify:0.3.0" ,
284
180
"org.mockito:mockito-core:2.28.2" ,
181
+ "org.pantsbuild:jarjar:1.7.2" ,
285
182
"org.objenesis:objenesis:1.0" ,
183
+ "org.ow2.asm:asm:%s" % ASM_VERSION ,
184
+ "org.ow2.asm:asm-tree:%s" % ASM_VERSION ,
185
+ "org.ow2.asm:asm-commons:%s" % ASM_VERSION ,
286
186
"org.robolectric:robolectric:4.4" ,
287
187
"org.robolectric:shadows-framework:4.4" , # For ActivityController
288
188
],
0 commit comments