commit | bf94dab4135743efb0c6eb675c846f060013f683 | [log] [tgz] |
---|---|---|
author | Jingwen Chen <jingwen@google.com> | Wed Jul 17 13:43:19 2019 -0700 |
committer | Copybara-Service <copybara-worker@google.com> | Wed Jul 17 13:44:44 2019 -0700 |
tree | cb7b36d5f432800171e4c5a326e2887b93863bf2 | |
parent | ed0f7d07821c9ee01882f54d6d75be110435034d [diff] |
Integrate Android NDK with toolchains Fixes https://github.com/bazelbuild/bazel/issues/8871 Generates toolchains for the `cc_toolchain` targets in the `@androidndk` BUILD file: ```python toolchain( name = "x86-clang8.0.7-libcpp_toolchain", toolchain_type = "@bazel_tools//tools/cpp:toolchain_type", target_compatible_with = [ "@bazel_tools//platforms:android", "@bazel_tools//platforms:x86_32" ], toolchain = "@androidndk//:x86-clang8.0.7-libcpp", ) toolchain( name = "x86_64-clang8.0.7-libcpp_toolchain", toolchain_type = "@bazel_tools//tools/cpp:toolchain_type", target_compatible_with = [ "@bazel_tools//platforms:android", "@bazel_tools//platforms:x86_64" ], toolchain = "@androidndk//:x86_64-clang8.0.7-libcpp", ) toolchain( name = "arm-linux-androideabi-clang8.0.7-v7a-libcpp_toolchain", toolchain_type = "@bazel_tools//tools/cpp:toolchain_type", target_compatible_with = [ "@bazel_tools//platforms:android", "@bazel_tools//platforms:arm" ], toolchain = "@androidndk//:arm-linux-androideabi-clang8.0.7-v7a-libcpp", ) toolchain( name = "aarch64-linux-android-clang8.0.7-libcpp_toolchain", toolchain_type = "@bazel_tools//tools/cpp:toolchain_type", target_compatible_with = [ "@bazel_tools//platforms:android", "@bazel_tools//platforms:aarch64" ], toolchain = "@androidndk//:aarch64-linux-android-clang8.0.7-libcpp", ) ``` Users can use them by using the `--extra_toolchains=@androidndk//:all` flag or by registering them in the WORKSPACE with `register_toolchains("androidndk//:all")`. RELNOTES: The Android NDK is now integrated with toolchains. To use them, pass the `--extra_toolchains=@androidndk//:all` flag or register them in your WORKSPACE with `register_toolchains("@androidndk//:all")`. Closes #8918. Change-Id: Iba708d1749efacbd47fc3584efd55634c70d2b18 PiperOrigin-RevId: 258633109
{Fast, Correct} - Choose two
Build and test software of any size, quickly and reliably.
Speed up your builds and tests: Bazel only rebuilds what is necessary. With advanced local and distributed caching, optimized dependency analysis and parallel execution, you get fast and incremental builds.
One tool, multiple languages: Build and test Java, C++, Android, iOS, Go, and a wide variety of other language platforms. Bazel runs on Windows, macOS, and Linux.
Scalable: Bazel helps you scale your organization, codebase, and continuous integration solution. It handles codebases of any size, in multiple repositories or a huge monorepo.
Extensible to your needs: Easily add support for new languages and platforms with Bazel's familiar extension language. Share and re-use language rules written by the growing Bazel community.
Follow our tutorials:
See CONTRIBUTING.md
Bazel is released in ‘Beta’. See the product roadmap to learn about the path toward a stable 1.0 release.