Some clarifications in preparation to automatically order linker dependencies
Test: Browse the code and determine whether it's easier to understand Bug: 66260943 Change-Id: Ia3fdb8f38e83ad8225a72c8de2804db23a90ef9b
This commit is contained in:
@@ -30,7 +30,7 @@ var (
|
||||
type AndroidMkContext interface {
|
||||
Target() android.Target
|
||||
subAndroidMk(*android.AndroidMkData, interface{})
|
||||
vndk() bool
|
||||
useVndk() bool
|
||||
}
|
||||
|
||||
type subAndroidMkProvider interface {
|
||||
@@ -64,14 +64,14 @@ func (c *Module) AndroidMk() android.AndroidMkData {
|
||||
if len(c.Properties.AndroidMkSharedLibs) > 0 {
|
||||
fmt.Fprintln(w, "LOCAL_SHARED_LIBRARIES := "+strings.Join(c.Properties.AndroidMkSharedLibs, " "))
|
||||
}
|
||||
if c.Target().Os == android.Android && c.Properties.Sdk_version != "" && !c.vndk() {
|
||||
if c.Target().Os == android.Android && c.Properties.Sdk_version != "" && !c.useVndk() {
|
||||
fmt.Fprintln(w, "LOCAL_SDK_VERSION := "+c.Properties.Sdk_version)
|
||||
fmt.Fprintln(w, "LOCAL_NDK_STL_VARIANT := none")
|
||||
} else {
|
||||
// These are already included in LOCAL_SHARED_LIBRARIES
|
||||
fmt.Fprintln(w, "LOCAL_CXX_STL := none")
|
||||
}
|
||||
if c.vndk() {
|
||||
if c.useVndk() {
|
||||
fmt.Fprintln(w, "LOCAL_USE_VNDK := true")
|
||||
}
|
||||
},
|
||||
@@ -89,7 +89,7 @@ func (c *Module) AndroidMk() android.AndroidMkData {
|
||||
}
|
||||
c.subAndroidMk(&ret, c.installer)
|
||||
|
||||
if c.vndk() && Bool(c.VendorProperties.Vendor_available) {
|
||||
if c.useVndk() && Bool(c.VendorProperties.Vendor_available) {
|
||||
// .vendor suffix is added only when we will have two variants: core and vendor.
|
||||
// The suffix is not added for vendor-only module.
|
||||
ret.SubName += vendorSuffix
|
||||
@@ -161,7 +161,7 @@ func (library *libraryDecorator) AndroidMk(ctx AndroidMkContext, ret *android.An
|
||||
}
|
||||
fmt.Fprintln(w, "LOCAL_MODULE_HOST_OS :=", makeOs)
|
||||
fmt.Fprintln(w, "LOCAL_IS_HOST_MODULE := true")
|
||||
} else if ctx.vndk() {
|
||||
} else if ctx.useVndk() {
|
||||
fmt.Fprintln(w, "LOCAL_USE_VNDK := true")
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user