BUILD 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. # Part of the Carbon Language project, under the Apache License v2.0 with LLVM
  2. # Exceptions. See /LICENSE for license information.
  3. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  4. load("@bazel_skylib//rules:common_settings.bzl", "bool_flag", "bool_setting", "int_flag")
  5. filegroup(
  6. name = "clang_tidy_config",
  7. srcs = [".clang-tidy"],
  8. visibility = ["//visibility:public"],
  9. )
  10. # `bazel run //:generate_compile_commands` to produce `compile_commands.json`.
  11. alias(
  12. name = "generate_compile_commands",
  13. actual = "@wolfd_bazel_compile_commands//:generate_compile_commands",
  14. )
  15. bool_setting(
  16. name = "runtimes_build",
  17. build_setting_default = False,
  18. visibility = ["//visibility:public"],
  19. )
  20. int_flag(
  21. name = "bootstrap_stage",
  22. build_setting_default = 0,
  23. visibility = ["//visibility:public"],
  24. )
  25. # A setting that causes bootstrapping to occur using the `exec` config rather
  26. # than the target config.
  27. #
  28. # The exec config is the more technically correct way of doing bootstrapping
  29. # than the target config. For example it allows bootstrapping with a target that
  30. # isn't compatible with the current execution host. However, in development
  31. # builds, it is likely to force building the entire toolchain twice -- once in
  32. # the target config for running test, and a second time in the exec config for
  33. # the bootstrap. As a consequence, this is disabled by default.
  34. #
  35. # TODO: Add documentation for using the bootstrap flags once stabilized.
  36. bool_flag(
  37. name = "bootstrap_exec_config",
  38. build_setting_default = False,
  39. visibility = ["//visibility:public"],
  40. )
  41. config_setting(
  42. name = "bootstrap_with_exec_config",
  43. flag_values = {"//:bootstrap_exec_config": "True"},
  44. visibility = ["//visibility:public"],
  45. )