Allow apis from exported shared library headers as well, while dumping abi.
header-abi-diff has switched to recursive diffing of types and can diff more accurately if types included in re-exported shared library headers are included as well. Bug: 62060883 Test: make -j64, android.hardware.light@2.0.so.lsdump contains structs from libcutils as well (libcutils' headers are re-exported by android.hardware.light@2.0) Change-Id: I814819e4f7258b4b380350fe8ad0ccf8dbd5ce5c
This commit is contained in:
@@ -184,7 +184,7 @@ var (
|
|||||||
// Abidiff check turned on in advice-only mode. Builds will not fail on abi incompatibilties / extensions.
|
// Abidiff check turned on in advice-only mode. Builds will not fail on abi incompatibilties / extensions.
|
||||||
sAbiDiff = pctx.AndroidStaticRule("sAbiDiff",
|
sAbiDiff = pctx.AndroidStaticRule("sAbiDiff",
|
||||||
blueprint.RuleParams{
|
blueprint.RuleParams{
|
||||||
Command: "$sAbiDiffer -lib $libName -arch $arch -advice-only -o ${out} -new $in -old $referenceDump",
|
Command: "$sAbiDiffer -lib $libName -arch $arch -advice-only -check-all-apis -o ${out} -new $in -old $referenceDump",
|
||||||
CommandDeps: []string{"$sAbiDiffer"},
|
CommandDeps: []string{"$sAbiDiffer"},
|
||||||
},
|
},
|
||||||
"referenceDump", "libName", "arch")
|
"referenceDump", "libName", "arch")
|
||||||
|
8
cc/cc.go
8
cc/cc.go
@@ -1028,11 +1028,9 @@ func (c *Module) depsToPaths(ctx android.ModuleContext) PathDeps {
|
|||||||
depPaths.ReexportedFlags = append(depPaths.ReexportedFlags, flags...)
|
depPaths.ReexportedFlags = append(depPaths.ReexportedFlags, flags...)
|
||||||
depPaths.ReexportedFlagsDeps = append(depPaths.ReexportedFlagsDeps, deps...)
|
depPaths.ReexportedFlagsDeps = append(depPaths.ReexportedFlagsDeps, deps...)
|
||||||
// Add these re-exported flags to help header-abi-dumper to infer the abi exported by a library.
|
// Add these re-exported flags to help header-abi-dumper to infer the abi exported by a library.
|
||||||
// Re-exported flags from shared library dependencies are not included as those shared libraries
|
// Re-exported shared library headers must be included as well since they can help us with type information
|
||||||
// will be included in the vndk set.
|
// about template instantiations (instantiated from their headers).
|
||||||
if tag == staticExportDepTag || tag == headerExportDepTag {
|
c.sabi.Properties.ReexportedIncludeFlags = append(c.sabi.Properties.ReexportedIncludeFlags, flags...)
|
||||||
c.sabi.Properties.ReexportedIncludeFlags = append(c.sabi.Properties.ReexportedIncludeFlags, flags...)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -323,9 +323,7 @@ func extractExportIncludesFromFlags(flags []string) []string {
|
|||||||
// from a source. We extract the include flags exported by a library.
|
// from a source. We extract the include flags exported by a library.
|
||||||
// This includes the flags exported which are re-exported from static
|
// This includes the flags exported which are re-exported from static
|
||||||
// library dependencies, exported header library dependencies and
|
// library dependencies, exported header library dependencies and
|
||||||
// generated header dependencies. Re-exported shared library include
|
// generated header dependencies. -isystem headers are not included
|
||||||
// flags are not in this set since shared library dependencies will
|
|
||||||
// themselves be included in the vndk. -isystem headers are not included
|
|
||||||
// since for bionic libraries, abi-filtering is taken care of by version
|
// since for bionic libraries, abi-filtering is taken care of by version
|
||||||
// scripts.
|
// scripts.
|
||||||
var exportedIncludes []string
|
var exportedIncludes []string
|
||||||
|
Reference in New Issue
Block a user