Merge "Support target.hostdex.required" am: 226586ca3c

am: 02a9b1af2c

Change-Id: Id2ad67edd62f10446e7786241b0518091239ab42
This commit is contained in:
Colin Cross 2019-04-24 17:31:15 -07:00 committed by android-build-merger
commit 53f0fd2cc3
2 changed files with 10 additions and 0 deletions

View File

@ -47,6 +47,9 @@ func (library *Library) AndroidMkHostDex(w io.Writer, name string, data android.
if len(data.Target_required) > 0 { if len(data.Target_required) > 0 {
fmt.Fprintln(w, "LOCAL_TARGET_REQUIRED_MODULES :=", strings.Join(data.Target_required, " ")) fmt.Fprintln(w, "LOCAL_TARGET_REQUIRED_MODULES :=", strings.Join(data.Target_required, " "))
} }
if r := library.deviceProperties.Target.Hostdex.Required; len(r) > 0 {
fmt.Fprintln(w, "LOCAL_REQUIRED_MODULES +=", strings.Join(r, " "))
}
fmt.Fprintln(w, "include $(BUILD_SYSTEM)/soong_java_prebuilt.mk") fmt.Fprintln(w, "include $(BUILD_SYSTEM)/soong_java_prebuilt.mk")
} }
} }

View File

@ -221,6 +221,13 @@ type CompilerDeviceProperties struct {
// If true, export a copy of the module as a -hostdex module for host testing. // If true, export a copy of the module as a -hostdex module for host testing.
Hostdex *bool Hostdex *bool
Target struct {
Hostdex struct {
// Additional required dependencies to add to -hostdex modules.
Required []string
}
}
// If set to true, compile dex regardless of installable. Defaults to false. // If set to true, compile dex regardless of installable. Defaults to false.
Compile_dex *bool Compile_dex *bool