aboutsummaryrefslogtreecommitdiffstats
path: root/genrule
diff options
context:
space:
mode:
authorDan Willemsen <dwillemsen@google.com>2015-11-24 17:53:15 -0800
committerDan Willemsen <dwillemsen@google.com>2015-11-30 15:28:31 -0800
commit490fd4955747c9d3715954359d72937960f02a22 (patch)
tree3b4ae5b86149ee178f60c21faf65e03ad7e23a51 /genrule
parent3b336c20566becb20324e25deb52ee08d8b1f9f8 (diff)
downloadbuild_soong-490fd4955747c9d3715954359d72937960f02a22.tar.gz
build_soong-490fd4955747c9d3715954359d72937960f02a22.tar.bz2
build_soong-490fd4955747c9d3715954359d72937960f02a22.zip
Support cross-compiling Windows binaries on Linux
This defines another mutator between HostOrDevice and Arch that will expand host modules into a module for each host type (Darwin/Linux/Windows) that is currently being built. Change-Id: I4c8ac6b616c229f6bd45ad8a35902652fb6a4fff
Diffstat (limited to 'genrule')
-rw-r--r--genrule/genrule.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/genrule/genrule.go b/genrule/genrule.go
index fb0dafcf..76b4f16a 100644
--- a/genrule/genrule.go
+++ b/genrule/genrule.go
@@ -88,8 +88,10 @@ func (g *generator) GeneratedSourceFiles() []string {
func genruleDepsMutator(ctx common.AndroidBottomUpMutatorContext) {
if g, ok := ctx.Module().(*generator); ok {
if g.properties.Tool != "" {
- ctx.AddFarVariationDependencies([]blueprint.Variation{{"hostordevice", common.Host.String()}},
- g.properties.Tool)
+ ctx.AddFarVariationDependencies([]blueprint.Variation{
+ {"host_or_device", common.Host.String()},
+ {"host_type", common.CurrentHostType().String()},
+ }, g.properties.Tool)
}
}
}