xref: /aosp_15_r20/external/bazel-skylib/BUILD (revision bcb5dc7965af6ee42bf2f21341a2ec00233a8c8a)
1*bcb5dc79SHONG Yifanload("@rules_license//rules:license.bzl", "license")
2*bcb5dc79SHONG Yifanload("//:bzl_library.bzl", "bzl_library")
3*bcb5dc79SHONG Yifan
4*bcb5dc79SHONG Yifanpackage(
5*bcb5dc79SHONG Yifan    default_applicable_licenses = ["//:license"],
6*bcb5dc79SHONG Yifan    default_visibility = ["//visibility:public"],
7*bcb5dc79SHONG Yifan)
8*bcb5dc79SHONG Yifan
9*bcb5dc79SHONG Yifanlicense(
10*bcb5dc79SHONG Yifan    name = "license",
11*bcb5dc79SHONG Yifan    package_name = "bazelbuild/bazel_skylib",
12*bcb5dc79SHONG Yifan    license_kinds = ["@rules_license//licenses/spdx:Apache-2.0"],
13*bcb5dc79SHONG Yifan)
14*bcb5dc79SHONG Yifan
15*bcb5dc79SHONG Yifanlicenses(["notice"])
16*bcb5dc79SHONG Yifan
17*bcb5dc79SHONG Yifan# buildifier: disable=skylark-comment
18*bcb5dc79SHONG Yifan# gazelle:exclude skylark_library.bzl
19*bcb5dc79SHONG Yifan
20*bcb5dc79SHONG Yifanexports_files([
21*bcb5dc79SHONG Yifan    "LICENSE",
22*bcb5dc79SHONG Yifan    "MODULE.bazel",
23*bcb5dc79SHONG Yifan    "WORKSPACE",
24*bcb5dc79SHONG Yifan])
25*bcb5dc79SHONG Yifan
26*bcb5dc79SHONG Yifanfilegroup(
27*bcb5dc79SHONG Yifan    name = "test_deps",
28*bcb5dc79SHONG Yifan    testonly = True,
29*bcb5dc79SHONG Yifan    srcs = [
30*bcb5dc79SHONG Yifan        "BUILD",
31*bcb5dc79SHONG Yifan        "//lib:test_deps",
32*bcb5dc79SHONG Yifan        "//rules:test_deps",
33*bcb5dc79SHONG Yifan        "//toolchains/unittest:test_deps",
34*bcb5dc79SHONG Yifan    ] + glob(["*.bzl"]),
35*bcb5dc79SHONG Yifan)
36*bcb5dc79SHONG Yifan
37*bcb5dc79SHONG Yifanbzl_library(
38*bcb5dc79SHONG Yifan    name = "lib",
39*bcb5dc79SHONG Yifan    srcs = ["lib.bzl"],
40*bcb5dc79SHONG Yifan    deprecation = (
41*bcb5dc79SHONG Yifan        "lib.bzl will go away in the future, please directly depend on the" +
42*bcb5dc79SHONG Yifan        " module(s) needed as it is more efficient."
43*bcb5dc79SHONG Yifan    ),
44*bcb5dc79SHONG Yifan    deps = [
45*bcb5dc79SHONG Yifan        "//lib:collections",
46*bcb5dc79SHONG Yifan        "//lib:dicts",
47*bcb5dc79SHONG Yifan        "//lib:new_sets",
48*bcb5dc79SHONG Yifan        "//lib:partial",
49*bcb5dc79SHONG Yifan        "//lib:paths",
50*bcb5dc79SHONG Yifan        "//lib:selects",
51*bcb5dc79SHONG Yifan        "//lib:sets",
52*bcb5dc79SHONG Yifan        "//lib:shell",
53*bcb5dc79SHONG Yifan        "//lib:structs",
54*bcb5dc79SHONG Yifan        "//lib:types",
55*bcb5dc79SHONG Yifan        "//lib:unittest",
56*bcb5dc79SHONG Yifan        "//lib:versions",
57*bcb5dc79SHONG Yifan    ],
58*bcb5dc79SHONG Yifan)
59*bcb5dc79SHONG Yifan
60*bcb5dc79SHONG Yifanbzl_library(
61*bcb5dc79SHONG Yifan    name = "bzl_library",
62*bcb5dc79SHONG Yifan    srcs = ["bzl_library.bzl"],
63*bcb5dc79SHONG Yifan)
64*bcb5dc79SHONG Yifan
65*bcb5dc79SHONG Yifanbzl_library(
66*bcb5dc79SHONG Yifan    name = "version",
67*bcb5dc79SHONG Yifan    srcs = ["version.bzl"],
68*bcb5dc79SHONG Yifan)
69*bcb5dc79SHONG Yifan
70*bcb5dc79SHONG Yifanbzl_library(
71*bcb5dc79SHONG Yifan    name = "workspace",
72*bcb5dc79SHONG Yifan    srcs = ["workspace.bzl"],
73*bcb5dc79SHONG Yifan)
74*bcb5dc79SHONG Yifan
75*bcb5dc79SHONG Yifan# The files needed for distribution.
76*bcb5dc79SHONG Yifan# TODO(aiuto): We should strip this from the release, but there is no
77*bcb5dc79SHONG Yifan# capability now to generate BUILD.foo from BUILD and have it appear in the
78*bcb5dc79SHONG Yifan# tarball as BUILD.
79*bcb5dc79SHONG Yifanfilegroup(
80*bcb5dc79SHONG Yifan    name = "distribution",
81*bcb5dc79SHONG Yifan    srcs = [
82*bcb5dc79SHONG Yifan        "BUILD",
83*bcb5dc79SHONG Yifan        "CODEOWNERS",
84*bcb5dc79SHONG Yifan        "CONTRIBUTORS",
85*bcb5dc79SHONG Yifan        "LICENSE",
86*bcb5dc79SHONG Yifan        "WORKSPACE.bzlmod",
87*bcb5dc79SHONG Yifan        "//lib:distribution",
88*bcb5dc79SHONG Yifan        "//rules:distribution",
89*bcb5dc79SHONG Yifan        "//rules/directory:distribution",
90*bcb5dc79SHONG Yifan        "//rules/directory/private:distribution",
91*bcb5dc79SHONG Yifan        "//rules/private:distribution",
92*bcb5dc79SHONG Yifan        "//toolchains/unittest:distribution",
93*bcb5dc79SHONG Yifan    ] + glob(["*.bzl"]),
94*bcb5dc79SHONG Yifan)
95