Using bzlmod with Bazel 6 or later:
-
[Bazel 6] Add
common --enable_bzlmodto.bazelrc. -
Add to your
MODULE.bazelfile:
bazel_dep(name = "rules_cc", version = "0.2.26")Using WORKSPACE:
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_cc",
sha256 = "44a8f325fa2b5cfb0ecaddda4365b3374eeefa1f97309fdb9301abb0897dfa7a",
strip_prefix = "rules_cc-0.2.26",
url = "https://github.com/bazelbuild/rules_cc/releases/download/0.2.26/rules_cc-0.2.26.tar.gz",
)
load("@rules_cc//cc:extensions.bzl", "compatibility_proxy_repo")
compatibility_proxy_repo()What's Changed
Notable changes
- Split coverage features into
coverage_enabledandcoverage_instrumented(#842) by @fmeum in 8ab086b - Propagate the profile changelist when MemProf comes from an fdo_profile rule. by @a-googler in cd02576
- Use compiler_files_without_includes for CcLtoBackendCompile actions. by @djasper-gh in 33af48d
- Fix linkstamping in external repos (#840) by @tobias17 in aeab566
- Fix cc_shared_library dependencies being included in runfiles (#882) by @keith in b712795
- Fix cc_shared_library locations with rules_python on windows (#909) by @keith in 1f56261
- Support checking command-line copts in disallowed copts policies by @a-googler in 785f33a
- Add back grep-includes alias (#888) by @keith in eaafbd3
Rules based toolchain changes
Full Changelog: 0.2.25...0.2.26