forked from bazelbuild/rules_kotlin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
BUILD
103 lines (92 loc) · 2.8 KB
/
BUILD
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
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
load("@rules_java//java:defs.bzl", "java_binary", "java_import", "java_library", "java_plugin")
load("//src/main/starlark/release:packager.bzl", "release_archive")
# Copyright 2018 The Bazel Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
package(default_visibility = ["//visibility:public"])
exports_files([
"empty.jdeps",
])
genrule(
name = "empty",
srcs = [
"empty-definately-not-binary-jar.txt",
],
outs = [
"empty.jar",
],
cmd = "cp $(location empty-definately-not-binary-jar.txt) $@",
)
java_plugin(
name = "autovalue_plugin",
generates_api = 1,
processor_class = "com.google.auto.value.processor.AutoValueProcessor",
visibility = ["//visibility:private"],
deps = ["@kotlin_rules_maven//:com_google_auto_value_auto_value"],
)
java_library(
name = "autovalue",
exported_plugins = [":autovalue_plugin"],
neverlink = 1,
exports = ["@kotlin_rules_maven//:com_google_auto_value_auto_value_annotations"],
)
java_plugin(
name = "dagger_component_plugin",
generates_api = 1,
processor_class = "dagger.internal.codegen.ComponentProcessor",
visibility = ["//visibility:private"],
deps = [
"@kotlin_rules_maven//:com_google_dagger_dagger_compiler",
],
)
java_library(
name = "dagger",
exported_plugins = [":dagger_component_plugin"],
exports = [
"@kotlin_rules_maven//:com_google_dagger_dagger",
"@kotlin_rules_maven//:javax_inject_javax_inject",
],
)
java_binary(
name = "jarjar_runner",
main_class = "org.pantsbuild.jarjar.Main",
visibility = ["//visibility:public"],
runtime_deps = ["@kotlin_rules_maven//:org_pantsbuild_jarjar"],
)
# TODO(bazelbuild/rules_kotlin/issues/273): Remove android_sdk import.
java_import(
name = "android_sdk",
jars = ["@bazel_tools//tools/android:android_jar"],
neverlink = 1,
visibility = ["//visibility:public"],
)
bzl_library(
name = "bzl",
srcs = [
"jarjar.bzl",
"@bazel_tools//tools:bzl_srcs",
],
)
release_archive(
name = "pkg",
srcs = [
"empty.jar",
"empty.jdeps",
"jarjar.bzl",
],
src_map = {
"jarjar_runner_deploy.jar": "jarjar.jar",
"BUILD.release.bazel": "BUILD.bazel",
},
)