• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2017 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 JSR-330 compliant dependency injection system for android and java
17
18load("@rules_java//java:defs.bzl", "java_library")
19load(
20    "//:build_defs.bzl",
21    "DOCLINT_HTML_AND_SYNTAX",
22    "POM_VERSION",
23    "SOURCE_7_TARGET_7",
24)
25load("//tools:maven.bzl", "pom_file")
26load("@google_bazel_common//tools/javadoc:javadoc.bzl", "javadoc_library")
27
28package(default_visibility = ["//:src"])
29
30java_library(
31    name = "core",
32    srcs = glob(["**/*.java"]),
33    javacopts = SOURCE_7_TARGET_7 + DOCLINT_HTML_AND_SYNTAX,
34    tags = ["maven_coordinates=com.google.dagger:dagger:" + POM_VERSION],
35    exports = ["@google_bazel_common//third_party/java/jsr330_inject"],
36    deps = [
37        "@google_bazel_common//third_party/java/jsr330_inject",
38    ],
39)
40
41pom_file(
42    name = "pom",
43    artifact_id = "dagger",
44    artifact_name = "Dagger",
45    targets = [":core"],
46)
47
48filegroup(
49    name = "javadoc-srcs",
50    srcs = glob(["**/*"]),
51)
52
53javadoc_library(
54    name = "core-javadoc",
55    srcs = [":javadoc-srcs"],
56    exclude_packages = ["dagger.internal"],
57    root_packages = ["dagger"],
58    deps = ["@google_bazel_common//third_party/java/jsr330_inject"],
59)
60