aboutsummaryrefslogtreecommitdiff
path: root/compiler_wrapper/command.go
diff options
context:
space:
mode:
authorTobias Bosch <tbosch@google.com>2019-10-17 07:44:13 -0700
committerTobias Bosch <tbosch@google.com>2019-10-17 19:22:03 +0000
commit8cb363f62b57954ace161789eb7fa692a24f29a4 (patch)
tree38c0358978d0dab8f34c6d7bd6004dff318ef7ec /compiler_wrapper/command.go
parent90d3658f7f8170c66f67f021df64bd421cdb7f11 (diff)
downloadtoolchain-utils-8cb363f62b57954ace161789eb7fa692a24f29a4.tar.gz
compiler_wrapper: remove WITH_TIDY support for android.
Also consolidates most of the android specific logic into one place so it's clear which flags are used and which ones are not. Also detects wrapping of clang-tidy for future special casing. BUG=chromium:773875 TEST=unit tests, golden tests TEST=android's test_compiler.py --with-tidy Change-Id: Ic83340ba63ec3ea4c3c174069d3dc017ecbcdd72 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/1866603 Tested-by: Tobias Bosch <tbosch@google.com> Reviewed-by: George Burgess <gbiv@chromium.org>
Diffstat (limited to 'compiler_wrapper/command.go')
-rw-r--r--compiler_wrapper/command.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler_wrapper/command.go b/compiler_wrapper/command.go
index 26f85568..69578597 100644
--- a/compiler_wrapper/command.go
+++ b/compiler_wrapper/command.go
@@ -129,6 +129,8 @@ func newCommandBuilder(env env, cfg *config, cmd *command) (*commandBuilder, err
var compilerType compilerType
switch {
+ case strings.HasPrefix(target.compiler, "clang-tidy"):
+ compilerType = clangTidyType
case strings.HasPrefix(target.compiler, "clang"):
compilerType = clangType
default:
@@ -172,6 +174,7 @@ type compilerType int32
const (
gccType compilerType = iota
clangType
+ clangTidyType
)
type builderTarget struct {