• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2019 The Dagger Authors.
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15# Description:
16#   A processor that aggregates metadata about Hilt @InstallIn annotations
17
18package(default_visibility = ["//:src"])
19
20# TODO(bcorso): Remove all AggregatedDeps usage from the processor class path.
21java_library(
22    name = "annotation",
23    srcs = ["AggregatedDeps.java"],
24    exports = [
25        "//java/dagger/hilt/codegen:originating_element",
26    ],
27)
28
29java_plugin(
30    name = "plugin",
31    generates_api = 1,
32    processor_class = "dagger.hilt.processor.internal.aggregateddeps.AggregatedDepsProcessor",
33    deps = [":processor_lib"],
34)
35
36java_library(
37    name = "processor_lib",
38    srcs = [
39        "AggregatedDepsGenerator.java",
40        "AggregatedDepsProcessor.java",
41        "PkgPrivateEntryPointGenerator.java",
42        "PkgPrivateMetadata.java",
43        "PkgPrivateModuleGenerator.java",
44    ],
45    deps = [
46        "//:dagger_with_compiler",
47        "//java/dagger/hilt/android/processor/internal/androidentrypoint:compiler_options",
48        "//java/dagger/hilt/processor/internal:base_processor",
49        "//java/dagger/hilt/processor/internal:classnames",
50        "//java/dagger/hilt/processor/internal:components",
51        "//java/dagger/hilt/processor/internal:kotlin",
52        "//java/dagger/hilt/processor/internal:processor_errors",
53        "//java/dagger/hilt/processor/internal:processors",
54        "//java/dagger/internal/codegen/extension",
55        "//java/dagger/internal/codegen/kotlin",
56        "//java/dagger/internal/guava:collect",
57        "@google_bazel_common//third_party/java/auto:service",
58        "@google_bazel_common//third_party/java/auto:value",
59        "@google_bazel_common//third_party/java/incap",
60        "@google_bazel_common//third_party/java/javapoet",
61        "@google_bazel_common//third_party/java/jsr250_annotations",
62        "@maven//:com_google_auto_auto_common",
63    ],
64)
65
66java_library(
67    name = "component_dependencies",
68    srcs = [
69        "ComponentDependencies.java",
70    ],
71    deps = [
72        ":processor_lib",
73        "//java/dagger/hilt/processor/internal:classnames",
74        "//java/dagger/hilt/processor/internal:component_descriptor",
75        "//java/dagger/hilt/processor/internal:processor_errors",
76        "//java/dagger/hilt/processor/internal:processors",
77        "//java/dagger/internal/codegen/extension",
78        "//java/dagger/internal/guava:base",
79        "//java/dagger/internal/guava:collect",
80        "@google_bazel_common//third_party/java/auto:value",
81        "@google_bazel_common//third_party/java/javapoet",
82    ],
83)
84
85filegroup(
86    name = "srcs_filegroup",
87    srcs = glob(["*"]),
88)
89