From 6b4419ccc7aeb96f714cfa0f1637f7a2343da3ba Mon Sep 17 00:00:00 2001 From: Dan Willemsen Date: Fri, 9 Aug 2019 12:45:53 -0700 Subject: [PATCH] Include dependencies for clang-tidy and header-abi-dumper We've been getting these dependencies transitively through the dependency on the object itself (which is a workaround for the lack of dep file support in these tools). But for remote builds to work, we need to know about these dependencies like any other object compilation. For regular builds, this increases the size of the ninja file by a few tens of megabytes (~1-2%). WITH_TIDY builds were already larger (~40-50%), but are now about 90% larger than a normal build. Test: treehugger Change-Id: Icdb4ca3d4d08d5706593d96d5c627149fa14fed8 --- cc/builder.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cc/builder.go b/cc/builder.go index 2909d51bd..89c418b69 100644 --- a/cc/builder.go +++ b/cc/builder.go @@ -498,7 +498,9 @@ func TransformSourceToObj(ctx android.ModuleContext, subdir string, srcFiles and Input: srcFile, // We must depend on objFile, since clang-tidy doesn't // support exporting dependencies. - Implicit: objFile, + Implicit: objFile, + Implicits: cFlagsDeps, + OrderOnly: pathDeps, Args: map[string]string{ "cFlags": moduleToolingCflags, "tidyFlags": flags.tidyFlags, @@ -516,6 +518,8 @@ func TransformSourceToObj(ctx android.ModuleContext, subdir string, srcFiles and Output: sAbiDumpFile, Input: srcFile, Implicit: objFile, + Implicits: cFlagsDeps, + OrderOnly: pathDeps, Args: map[string]string{ "cFlags": moduleToolingCflags, "exportDirs": flags.sAbiFlags,