aboutsummaryrefslogtreecommitdiffstats
path: root/android/androidmk.go
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2017-10-09 14:59:32 -0700
committerColin Cross <ccross@android.com>2017-10-10 08:02:20 -0700
commit92430106c3c96d8a2cce2e4cb5a7746517c3965f (patch)
treefd27929e6a32e64813af65765afbfa0eec5bbc2e /android/androidmk.go
parent89479facb9d8dbd7fb2838128b08a9fc5e74fe57 (diff)
downloadbuild_soong-92430106c3c96d8a2cce2e4cb5a7746517c3965f.tar.gz
build_soong-92430106c3c96d8a2cce2e4cb5a7746517c3965f.tar.bz2
build_soong-92430106c3c96d8a2cce2e4cb5a7746517c3965f.zip
Add hostdex support
If hostdex: true is specified for a java library, create an extra Make module that copies the dex jar to a module with a -hostdex suffix in the host output directory. Bug: 67600882 Test: m -j checkbuild Change-Id: I859dfaabeefdca714b566de94e00f74e03c85939
Diffstat (limited to 'android/androidmk.go')
-rw-r--r--android/androidmk.go7
1 files changed, 5 insertions, 2 deletions
diff --git a/android/androidmk.go b/android/androidmk.go
index 5ce486da..759d3282 100644
--- a/android/androidmk.go
+++ b/android/androidmk.go
@@ -43,6 +43,7 @@ type AndroidMkData struct {
OutputFile OptionalPath
Disabled bool
Include string
+ Required []string
Custom func(w io.Writer, name, prefix, moduleDir string, data AndroidMkData)
@@ -168,6 +169,8 @@ func translateAndroidMkModule(ctx blueprint.SingletonContext, w io.Writer, mod b
data.Include = "$(BUILD_PREBUILT)"
}
+ data.Required = amod.commonProperties.Required
+
// Make does not understand LinuxBionic
if amod.Os() == LinuxBionic {
return nil
@@ -197,8 +200,8 @@ func translateAndroidMkModule(ctx blueprint.SingletonContext, w io.Writer, mod b
fmt.Fprintln(&data.preamble, "LOCAL_MODULE_CLASS :=", data.Class)
fmt.Fprintln(&data.preamble, "LOCAL_PREBUILT_MODULE_FILE :=", data.OutputFile.String())
- if len(amod.commonProperties.Required) > 0 {
- fmt.Fprintln(&data.preamble, "LOCAL_REQUIRED_MODULES := "+strings.Join(amod.commonProperties.Required, " "))
+ if len(data.Required) > 0 {
+ fmt.Fprintln(&data.preamble, "LOCAL_REQUIRED_MODULES := "+strings.Join(data.Required, " "))
}
archStr := amod.Arch().ArchType.String()