Add native_coverage to product variables
Allow native_coverage to adjust sources in product_variables. Fixes: 148088129 Test: m checkbuild Change-Id: I9c9d491cda92d69726a0d598408de2060241365b
This commit is contained in:
@@ -1024,7 +1024,7 @@ func (c *deviceConfig) DeviceKernelHeaderDirs() []string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (c *deviceConfig) NativeCoverageEnabled() bool {
|
func (c *deviceConfig) NativeCoverageEnabled() bool {
|
||||||
return Bool(c.config.productVariables.NativeCoverage)
|
return Bool(c.config.productVariables.Native_coverage)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *deviceConfig) ClangCoverageEnabled() bool {
|
func (c *deviceConfig) ClangCoverageEnabled() bool {
|
||||||
|
@@ -123,6 +123,11 @@ type variableProperties struct {
|
|||||||
Experimental_mte struct {
|
Experimental_mte struct {
|
||||||
Cflags []string `android:"arch_variant"`
|
Cflags []string `android:"arch_variant"`
|
||||||
} `android:"arch_variant"`
|
} `android:"arch_variant"`
|
||||||
|
|
||||||
|
Native_coverage struct {
|
||||||
|
Srcs []string `android:"arch_variant"`
|
||||||
|
Exclude_srcs []string `android:"arch_variant"`
|
||||||
|
} `android:"arch_variant"`
|
||||||
} `android:"arch_variant"`
|
} `android:"arch_variant"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -242,7 +247,7 @@ type productVariables struct {
|
|||||||
ClangTidy *bool `json:",omitempty"`
|
ClangTidy *bool `json:",omitempty"`
|
||||||
TidyChecks *string `json:",omitempty"`
|
TidyChecks *string `json:",omitempty"`
|
||||||
|
|
||||||
NativeCoverage *bool `json:",omitempty"`
|
Native_coverage *bool `json:",omitempty"`
|
||||||
ClangCoverage *bool `json:",omitempty"`
|
ClangCoverage *bool `json:",omitempty"`
|
||||||
CoveragePaths []string `json:",omitempty"`
|
CoveragePaths []string `json:",omitempty"`
|
||||||
CoverageExcludePaths []string `json:",omitempty"`
|
CoverageExcludePaths []string `json:",omitempty"`
|
||||||
|
@@ -82,7 +82,7 @@ func TestVndkApexUsesVendorVariant(t *testing.T) {
|
|||||||
notice: "custom_notice",
|
notice: "custom_notice",
|
||||||
}
|
}
|
||||||
`, func(fs map[string][]byte, config android.Config) {
|
`, func(fs map[string][]byte, config android.Config) {
|
||||||
config.TestProductVariables.NativeCoverage = proptools.BoolPtr(true)
|
config.TestProductVariables.Native_coverage = proptools.BoolPtr(true)
|
||||||
})
|
})
|
||||||
|
|
||||||
files := getFiles(t, ctx, "myapex", "android_common_image")
|
files := getFiles(t, ctx, "myapex", "android_common_image")
|
||||||
|
Reference in New Issue
Block a user