diff options
author | Liz Kammer <eakammer@google.com> | 2021-12-16 18:38:24 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2021-12-16 18:38:24 +0000 |
commit | bfd753b963ff8d8c838f3485f009fae58b2ccc00 (patch) | |
tree | addb78d2d10fffc157acdc591418e07fcb651ad5 | |
parent | 18eabbe5eeea901b5bee640d44f10b2747e5709e (diff) | |
parent | bbbbf5b0ca362a0706edb952196ac68942ff1713 (diff) | |
download | linux-x86-bfd753b963ff8d8c838f3485f009fae58b2ccc00.tar.gz |
Merge "Add external compiler flag feature" am: 0eb3e1a100 am: bbbbf5b0ca
Original change: https://android-review.googlesource.com/c/platform/prebuilts/clang/host/linux-x86/+/1924583
Change-Id: I1393b369dc351d060e74b20db5340eef4e01514f
-rw-r--r-- | cc_toolchain_features.bzl | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/cc_toolchain_features.bzl b/cc_toolchain_features.bzl index ba57b46a0..dff558bf1 100644 --- a/cc_toolchain_features.bzl +++ b/cc_toolchain_features.bzl @@ -179,6 +179,11 @@ def _compiler_flag_features(flags = [], os_is_device = False): flags = non_external_flags, ), ], + with_features = [ + with_feature_set( + not_features = ["external_compiler_flags"], + ), + ], ), ], )) @@ -239,6 +244,25 @@ def _compiler_flag_features(flags = [], os_is_device = False): ), ], )) + features.append(feature( + name = "external_compiler_flags", + enabled = True, + flag_sets = [ + flag_set( + actions = _actions.compile, + flag_groups = [ + flag_group( + flags = _generated_constants.ExternalCflags, + ), + ], + with_features = [ + with_feature_set( + not_features = ["non_external_compiler_flags"], + ), + ], + ), + ], + )) # The user_compile_flags feature is used by Bazel to add --copt, --conlyopt, # and --cxxopt values. Any features added above this call will thus appear |