commit | 0d5f3f2768c6ca2faca0079a997a97ce22997a0c | [log] [tgz] |
---|---|---|
author | Googler <plf@google.com> | Thu Jun 27 09:00:04 2019 -0700 |
committer | Copybara-Service <copybara-worker@google.com> | Thu Jun 27 09:00:21 2019 -0700 |
tree | df30b419f5f4299d4dfcc3808416ba50b1f35f52 | |
parent | d36c8d400c6fe78465e7ab690534ac83c61462aa [diff] |
C++: Adds macros for wrapping C++ rules. See: https://docs.google.com/document/d/1PgCYKVUBpFA0ZXTHTgHhUiLGgTRPloxKJ2d2t47TNo4/edit?usp=sharing RELNOTES:none PiperOrigin-RevId: 255411415 Change-Id: I319fac86118d051644a19422d1f474bec2538774
This repository contains Starlark implementation of C++ rules in Bazel.
The rules are being incrementally converted from their native implementations in the Bazel source tree.
For the list of C++ rules, see the Bazel documentation.
There is no need to use rules from this repository just yet. If you want to use rules_cc anyway, add the following to your WORKSPACE file:
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") http_archive( name = "rules_cc", urls = ["https://github.com/bazelbuild/rules_cc/archive/TODO"], sha256 = "TODO", )
Then, in your BUILD files, import and use the rules:
load("@rules_cc//cc:defs.bzl", "cc_library") cc_library( ... )
This repository also contains migration tools that can be used to migrate your project for Bazel incompatible changes.
Script that migrates legacy crosstool fields into features (incompatible flag, tracking issue).
TLDR:
bazel run @rules_cc//tools/migration:legacy_fields_migrator -- \ --input=my_toolchain/CROSSTOOL \ --inline
Bazel and rules_cc are the work of many contributors. We appreciate your help!
To contribute, please read the contribution guidelines: CONTRIBUTING.md.
Note that the rules_cc use the GitHub issue tracker for bug reports and feature requests only. For asking questions see:
#cc
on slack.bazel.build