Support opt-in ABI checks

This commit allows a module to opt in for ABI checks even when it is
not an LLNDK/VNDK module.

Bug: 131421213
Test: Add `header_abi_checker { enabled: true, }` to some module
Change-Id: Ie09d262e651cbb44d7d0eba652f55dc1e1e52962
This commit is contained in:
Logan Chien
2019-04-10 13:33:58 +08:00
parent 9a4abed701
commit 41eabe63e8
5 changed files with 49 additions and 18 deletions

View File

@@ -19,6 +19,7 @@ package cc
// is handled in builder.go
import (
"io"
"strconv"
"strings"
@@ -1966,6 +1967,14 @@ func (c *Module) IDEInfo(dpInfo *android.IdeInfo) {
dpInfo.Srcs = append(dpInfo.Srcs, c.Srcs().Strings()...)
}
func (c *Module) AndroidMkWriteAdditionalDependenciesForSourceAbiDiff(w io.Writer) {
if c.linker != nil {
if library, ok := c.linker.(*libraryDecorator); ok {
library.androidMkWriteAdditionalDependenciesForSourceAbiDiff(w)
}
}
}
//
// Defaults
//