Support system/vendor for devices without a vendor partition

Test: lunch aosp_arm-eng; m -j vulkan.default
Change-Id: I91eabf98f53c455ec4ade95215f11a6f89631747
This commit is contained in:
Dan Willemsen
2016-12-05 17:16:02 -08:00
parent 7ed1ae3fa4
commit 4353bc4422
3 changed files with 10 additions and 1 deletions

View File

@@ -443,6 +443,13 @@ func (c *deviceConfig) Arches() []Arch {
return arches
}
func (c *deviceConfig) VendorPath() string {
if c.config.ProductVariables.VendorPath != nil {
return *c.config.ProductVariables.VendorPath
}
return "vendor"
}
func (c *deviceConfig) VndkVersion() string {
if c.config.ProductVariables.DeviceVndkVersion == nil {
return ""

View File

@@ -631,7 +631,7 @@ func PathForModuleInstall(ctx ModuleContext, paths ...string) OutputPath {
if ctx.Device() {
partition := "system"
if ctx.Proprietary() {
partition = "vendor"
partition = ctx.DeviceConfig().VendorPath()
}
if ctx.InstallInData() {
partition = "data"

View File

@@ -113,6 +113,8 @@ type productVariables struct {
UseGoma *bool `json:",omitempty"`
Debuggable *bool `json:",omitempty"`
VendorPath *string `json:",omitempty"`
ClangTidy *bool `json:",omitempty"`
TidyChecks *string `json:",omitempty"`