mirror of https://github.com/bazelbuild/rules_cc
Remove unnecessary allowlist_include_directories
This commit is contained in:
parent
8faacdf7e3
commit
72d3b34612
|
@ -0,0 +1,13 @@
|
||||||
|
# Rule-based toolchains
|
||||||
|
This example showcases a fully working rule-based toolchain for Linux. This also
|
||||||
|
serves as an integration test to ensure rule-based toolchains continue to work
|
||||||
|
as intended.
|
||||||
|
|
||||||
|
The complete toolchain configuration lives [here](https://github.com/bazelbuild/rules_cc/tree/main/examples/rule_based_toolchain/toolchain).
|
||||||
|
|
||||||
|
# Trying the example
|
||||||
|
From this directory, you can run example tests that build using this toolchain
|
||||||
|
with the following command:
|
||||||
|
```
|
||||||
|
$ bazel test //...
|
||||||
|
```
|
|
@ -81,14 +81,11 @@ cc_tool(
|
||||||
"@platforms//os:windows": "//:bin/clang.exe",
|
"@platforms//os:windows": "//:bin/clang.exe",
|
||||||
"//conditions:default": "//:bin/clang",
|
"//conditions:default": "//:bin/clang",
|
||||||
}),
|
}),
|
||||||
allowlist_include_directories = [
|
|
||||||
":lib-clang-include",
|
|
||||||
],
|
|
||||||
data = glob([
|
data = glob([
|
||||||
"bin/llvm",
|
"bin/llvm",
|
||||||
"include/**",
|
]) + [
|
||||||
"lib/clang/**/include/**",
|
":lib-clang-include",
|
||||||
]),
|
],
|
||||||
)
|
)
|
||||||
|
|
||||||
cc_tool(
|
cc_tool(
|
||||||
|
@ -97,16 +94,13 @@ cc_tool(
|
||||||
"@platforms//os:windows": "//:bin/clang++.exe",
|
"@platforms//os:windows": "//:bin/clang++.exe",
|
||||||
"//conditions:default": "//:bin/clang++",
|
"//conditions:default": "//:bin/clang++",
|
||||||
}),
|
}),
|
||||||
allowlist_include_directories = [
|
data = glob([
|
||||||
|
"bin/llvm",
|
||||||
|
]) + [
|
||||||
":include-x86_64-unknown-linux-gnu-c++-v1",
|
":include-x86_64-unknown-linux-gnu-c++-v1",
|
||||||
":include-c++-v1",
|
":include-c++-v1",
|
||||||
":lib-clang-include",
|
":lib-clang-include",
|
||||||
],
|
],
|
||||||
data = glob([
|
|
||||||
"bin/llvm",
|
|
||||||
"include/**",
|
|
||||||
"lib/clang/**/include/**",
|
|
||||||
]),
|
|
||||||
)
|
)
|
||||||
|
|
||||||
cc_tool(
|
cc_tool(
|
||||||
|
|
|
@ -20,11 +20,11 @@ package(default_visibility = ["//visibility:public"])
|
||||||
|
|
||||||
cc_sysroot(
|
cc_sysroot(
|
||||||
name = "sysroot",
|
name = "sysroot",
|
||||||
allowlist_include_directories = [
|
data = [
|
||||||
|
":root",
|
||||||
":usr-include-x86_64-linux-gnu",
|
":usr-include-x86_64-linux-gnu",
|
||||||
":usr-include",
|
":usr-include",
|
||||||
],
|
],
|
||||||
data = [":root"],
|
|
||||||
sysroot = ":root",
|
sysroot = ":root",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue