0.2.0
0.2.0
https://bazelbuild.github.io/rules_foreign_cc/0.2.0/
Usage
Add the following to your WORKSPACE
file:
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_foreign_cc",
sha256 = "d54742ffbdc6924f222d2179f0e10e911c5c659c4ae74158e9fe827aad862ac6",
strip_prefix = "rules_foreign_cc-0.2.0",
url = "https://github.com/bazelbuild/rules_foreign_cc/archive/0.2.0.tar.gz",
)
load("@rules_foreign_cc//foreign_cc:repositories.bzl", "rules_foreign_cc_dependencies")
# This sets up some common toolchains for building targets. For more details, please see
# https://bazelbuild.github.io/rules_foreign_cc/0.2.0/#rules_foreign_cc_dependencies
rules_foreign_cc_dependencies()
Migration Instructions
Existing code should continue to work but the following migrations should be made to ensure future compatibility with these rules:
- Update load paths containing
tools/build_defs
toforeign_cc
- Update load paths
for_workspace
toforeign_cc
- Update loads of
workspace_definitions.bzl
toforeign_cc:repositories.bzl
- Migrate use of
keep_going
inmake
targets to explicitly pass-k
or patch the Makefile so that it doesn't require the keep going behaviour.
Release Notes
@rules_foreign_cc//foreign_cc:defs.bzl
was introduced and contains all common build rules. #555- Symbols in
tools/build_defs
andfor_workspace
and have been moved intoforeign_cc
. Users should update their load statements to use the new paths. #555 #557 - Toolchain definitions are now located in
toolchains
. #541 - The
cmake_external
rule has been renamed tocmake
. #539 - A new
targets
attribute was added to thecmake
,configure_make
, andmake
rules. This should be used overmake_commands
for building targets. #556 - The
make
rule no longer passes thePREFIX
argument as part of the default build command. #556 - The
keep_going
attribute (previously defaulted toTrue
) is deprecated, users can maintain this behavior by passing-k
themselves. #556 - Logs from built tools are now written to a file and only printed to the terminal when the target fails to build. #559
- Output attributes on common rules have been renamed from
*_libraries
toout_*_libs
. #538 - Downloaded CMake tools should now work on docker-sandbox / RBE #545
- The min supported version is raised from
3.4.0
to3.7.0
. #561
Known Issues
- The built make tool doesn't work on RBE.