sandboxed-api/sandboxed_api/tools/clang_generator
Christian Blichmann 74bb2c35ca bazel: Add build rules for the new interface generator
This adds a workspace rule that inspects the current system first and
downloads a suitable version of LLVM/Clang from GitHub if it can't
find one. In the latter case, the necessary parts are build from source,
which can take a while (~10-15m, depending on the build machine).

In order to be found, LLVM/Clang system libraries must be version 11
or higher. On Debian/Ubuntu, install `llvm-13-dev` and `libclang-13-dev`.

The new `llvm_config.bzl` implements this logic. It is loosely based on
upstream's https://github.com/llvm/llvm-project/blob/main/utils/bazel/configure.bzl.
Note that due to the way Bazel separates local repositories, we have to
duplictate some of this code.

PiperOrigin-RevId: 438759950
Change-Id: Ia65f473b4cdef6507e3816bf09794ea10963d87a
2022-04-01 00:55:30 -07:00
..
BUILD bazel: Add build rules for the new interface generator 2022-04-01 00:55:30 -07:00
CMakeLists.txt clang_generator: Enable mixed header processing 2022-03-17 03:41:53 -07:00
compilation_database.cc clang_generator: Enable mixed header processing 2022-03-17 03:41:53 -07:00
compilation_database.h clang_generator: Enable mixed header processing 2022-03-17 03:41:53 -07:00
diagnostics.cc Change license link to HTTPS URL 2022-01-28 01:39:09 -08:00
diagnostics.h Change license link to HTTPS URL 2022-01-28 01:39:09 -08:00
emitter_test.cc clang_generator: Do not collect structs/unions if declared in another record 2022-03-17 03:30:12 -07:00
emitter.cc clang_generator: Improve formatting of function prototype comments 2022-03-17 03:53:13 -07:00
emitter.h clang_generator: Improve formatting of function prototype comments 2022-03-17 03:53:13 -07:00
frontend_action_test_util.cc clang_generator: Do not collect structs/unions if declared in another record 2022-03-17 03:30:12 -07:00
frontend_action_test_util.h clang_generator: Do not collect structs/unions if declared in another record 2022-03-17 03:30:12 -07:00
generator_tool.cc clang_generator: Enable mixed header processing 2022-03-17 03:41:53 -07:00
generator.cc clang_generator: Handle intrinsics directly 2022-03-17 02:31:57 -07:00
generator.h clang_generator: Handle intrinsics directly 2022-03-17 02:31:57 -07:00
types.cc clang_generator: Map C's _Bool to bool 2022-03-21 04:11:21 -07:00
types.h Change license link to HTTPS URL 2022-01-28 01:39:09 -08:00