From da714efa6a5128abe9542b7b7cb2d340c6bb1cad Mon Sep 17 00:00:00 2001 From: Keith Smiley Date: Thu, 13 Aug 2020 15:53:06 -0700 Subject: [PATCH] Add bzl_library targets These are useful for stardoc from other rules repos --- proto/BUILD | 20 ++++++++++++++++++++ proto/private/BUILD | 12 ++++++++++++ tests/load_from_macro/BUILD | 8 ++++++++ 3 files changed, 40 insertions(+) diff --git a/proto/BUILD b/proto/BUILD index 5990249..db77862 100644 --- a/proto/BUILD +++ b/proto/BUILD @@ -1 +1,21 @@ +load("@bazel_skylib//:bzl_library.bzl", "bzl_library") + # Intentionally left empty (for now). + +bzl_library( + name = "defs", + srcs = ["defs.bzl"], + visibility = ["//visibility:public"], + deps = ["@rules_proto//proto/private:native"], +) + +bzl_library( + name = "repositories", + srcs = ["repositories.bzl"], + visibility = ["//visibility:public"], + deps = [ + "@bazel_tools//tools/build_defs/repo:http", + "@bazel_tools//tools/build_defs/repo:utils", + "@rules_proto//proto/private:dependencies", + ], +) diff --git a/proto/private/BUILD b/proto/private/BUILD index 5990249..f635213 100644 --- a/proto/private/BUILD +++ b/proto/private/BUILD @@ -1 +1,13 @@ +load("@bazel_skylib//:bzl_library.bzl", "bzl_library") + # Intentionally left empty (for now). + +bzl_library( + name = "dependencies", + srcs = ["dependencies.bzl"], +) + +bzl_library( + name = "native", + srcs = ["native.bzl"], +) diff --git a/tests/load_from_macro/BUILD b/tests/load_from_macro/BUILD index eb50d3d..2a4d4f4 100644 --- a/tests/load_from_macro/BUILD +++ b/tests/load_from_macro/BUILD @@ -1,3 +1,5 @@ +load("@bazel_skylib//:bzl_library.bzl", "bzl_library") + # Copyright 2019 The Bazel Authors. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -20,3 +22,9 @@ proto_library( srcs = ["foo.proto"], tags = TAGS, ) + +bzl_library( + name = "tags", + srcs = ["tags.bzl"], + visibility = ["//visibility:public"], +)