mirror of https://github.com/bazelbuild/rules_cc
Internal change
PiperOrigin-RevId: 339887089 Change-Id: Ic511ced72381f847f5d1b9159f299b6e474a47de
This commit is contained in:
parent
8cded3e3c3
commit
16ad606329
14
BUILD
14
BUILD
|
@ -1,3 +1,5 @@
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
|
|
||||||
package(default_visibility = ["//visibility:public"])
|
package(default_visibility = ["//visibility:public"])
|
||||||
|
|
||||||
licenses(["notice"])
|
licenses(["notice"])
|
||||||
|
@ -14,3 +16,15 @@ filegroup(
|
||||||
],
|
],
|
||||||
visibility = ["@//distro:__pkg__"],
|
visibility = ["@//distro:__pkg__"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "internal_deps_bzl",
|
||||||
|
srcs = ["internal_deps.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "internal_setup_bzl",
|
||||||
|
srcs = ["internal_setup.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
load("@bazel_skylib//rules:common_settings.bzl", "bool_flag")
|
load("@bazel_skylib//rules:common_settings.bzl", "bool_flag")
|
||||||
|
|
||||||
# A collection of examples showing the usage of rules_cc
|
# A collection of examples showing the usage of rules_cc
|
||||||
|
@ -28,3 +29,9 @@ bool_flag(
|
||||||
build_setting_default = False,
|
build_setting_default = False,
|
||||||
visibility = ["//visibility:public"],
|
visibility = ["//visibility:public"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "experimental_cc_shared_library_bzl",
|
||||||
|
srcs = ["experimental_cc_shared_library.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -14,6 +14,7 @@
|
||||||
|
|
||||||
# Example showing how to create a custom Starlark rule that rules_cc can depend on
|
# Example showing how to create a custom Starlark rule that rules_cc can depend on
|
||||||
|
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_library")
|
load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_library")
|
||||||
load("//examples/my_c_archive:my_c_archive.bzl", "my_c_archive")
|
load("//examples/my_c_archive:my_c_archive.bzl", "my_c_archive")
|
||||||
load("//examples/my_c_compile:my_c_compile.bzl", "my_c_compile")
|
load("//examples/my_c_compile:my_c_compile.bzl", "my_c_compile")
|
||||||
|
@ -41,3 +42,9 @@ cc_library(
|
||||||
name = "bar",
|
name = "bar",
|
||||||
srcs = ["bar.c"],
|
srcs = ["bar.c"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "my_c_archive_bzl",
|
||||||
|
srcs = ["my_c_archive.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
load("//examples/my_c_compile:my_c_compile.bzl", "my_c_compile")
|
load("//examples/my_c_compile:my_c_compile.bzl", "my_c_compile")
|
||||||
|
|
||||||
# Copyright 2019 The Bazel Authors. All rights reserved.
|
# Copyright 2019 The Bazel Authors. All rights reserved.
|
||||||
|
@ -21,3 +22,9 @@ my_c_compile(
|
||||||
name = "foo",
|
name = "foo",
|
||||||
src = "foo.c",
|
src = "foo.c",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "my_c_compile_bzl",
|
||||||
|
srcs = ["my_c_compile.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
load("//cc:defs.bzl", "cc_binary", "cc_library", "cc_test")
|
load("//cc:defs.bzl", "cc_binary", "cc_library", "cc_test")
|
||||||
load("//examples:experimental_cc_shared_library.bzl", "LINKABLE_MORE_THAN_ONCE", "cc_shared_library")
|
load("//examples:experimental_cc_shared_library.bzl", "LINKABLE_MORE_THAN_ONCE", "cc_shared_library")
|
||||||
load(":starlark_tests.bzl", "additional_inputs_test", "build_failure_test", "linking_suffix_test", "paths_test")
|
load(":starlark_tests.bzl", "additional_inputs_test", "build_failure_test", "linking_suffix_test", "paths_test")
|
||||||
|
@ -195,3 +196,9 @@ build_failure_test(
|
||||||
message = "can only list targets that are in the same package or a sub-package",
|
message = "can only list targets that are in the same package or a sub-package",
|
||||||
target_under_test = "//examples/test_cc_shared_library/failing_targets:permissions_fail",
|
target_under_test = "//examples/test_cc_shared_library/failing_targets:permissions_fail",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "test_cc_shared_library_starlark_tests_bzl",
|
||||||
|
srcs = ["starlark_tests.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
load("//examples/write_cc_toolchain_cpu:write_cc_toolchain_cpu.bzl", "write_cc_toolchain_cpu")
|
load("//examples/write_cc_toolchain_cpu:write_cc_toolchain_cpu.bzl", "write_cc_toolchain_cpu")
|
||||||
|
|
||||||
# Copyright 2019 The Bazel Authors. All rights reserved.
|
# Copyright 2019 The Bazel Authors. All rights reserved.
|
||||||
|
@ -18,3 +19,9 @@ load("//examples/write_cc_toolchain_cpu:write_cc_toolchain_cpu.bzl", "write_cc_t
|
||||||
licenses(["notice"])
|
licenses(["notice"])
|
||||||
|
|
||||||
write_cc_toolchain_cpu(name = "write_me_the_cpu")
|
write_cc_toolchain_cpu(name = "write_me_the_cpu")
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "write_cc_toolchain_cpu_bzl",
|
||||||
|
srcs = ["write_cc_toolchain_cpu.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
load("//cc:defs.bzl", "cc_library")
|
load("//cc:defs.bzl", "cc_library")
|
||||||
load(":tags.bzl", "TAGS")
|
load(":tags.bzl", "TAGS")
|
||||||
|
|
||||||
|
@ -22,3 +23,9 @@ cc_library(
|
||||||
srcs = ["foo.cc"],
|
srcs = ["foo.cc"],
|
||||||
tags = TAGS,
|
tags = TAGS,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "tags_bzl",
|
||||||
|
srcs = ["tags.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
|
@ -12,6 +12,8 @@
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
|
|
||||||
# Go rules
|
# Go rules
|
||||||
load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
|
load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
|
||||||
|
|
||||||
|
@ -131,3 +133,15 @@ filegroup(
|
||||||
)
|
)
|
||||||
|
|
||||||
exports_files(["ctoolchain_compare.bzl"])
|
exports_files(["ctoolchain_compare.bzl"])
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "ctoolchain_compare_bzl",
|
||||||
|
srcs = ["ctoolchain_compare.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
||||||
|
bzl_library(
|
||||||
|
name = "cc_toolchain_config_comparator_bzl",
|
||||||
|
srcs = ["cc_toolchain_config_comparator.bzl"],
|
||||||
|
visibility = ["//visibility:private"],
|
||||||
|
)
|
||||||
|
|
Loading…
Reference in New Issue