diff options
author | Octavian Purdila <tavip@google.com> | 2024-02-23 16:05:55 -0800 |
---|---|---|
committer | Octavian Purdila <tavip@google.com> | 2024-02-29 11:19:42 -0800 |
commit | 14883185a4d54d4a1224075f5672cbafab675d4b (patch) | |
tree | 6f74aba57c231a13bdb0274d8a479d29cc6314eb | |
parent | 47591b63270e26e8b2bf80f7809dc79886245a97 (diff) | |
download | cuttlefish-14883185a4d54d4a1224075f5672cbafab675d4b.tar.gz |
Allow target specific binaries in the cvd host package
Add support for customizing the cvd host package with target specific
binaries.
To add a target specific binary to the cvd host package add the
following in one of the target .mk files:
$(call soong_config_append,cvd,binary, test-binary)
Bug: 318734012
Test: m dist and check the cvd host tarball
Change-Id: I6c10ead8b1caefe903521cb712c678e12b95f358
-rw-r--r-- | build/cvd-host-package.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/build/cvd-host-package.go b/build/cvd-host-package.go index cf66c0e99..596ce41d0 100644 --- a/build/cvd-host-package.go +++ b/build/cvd-host-package.go @@ -68,6 +68,13 @@ func (c *cvdHostPackage) DepsMutator(ctx android.BottomUpMutatorContext) { } } + for _, dep := range strings.Split( + ctx.Config().VendorConfig("cvd").String("binary"), " ") { + if ctx.OtherModuleExists(dep) { + ctx.AddVariationDependencies(ctx.Target().Variations(), cvdHostPackageDependencyTag, dep) + } + } + // If cvd_custom_action_config is set, include custom action servers in the // host package as specified by cvd_custom_action_servers. customActionConfig := ctx.Config().VendorConfig("cvd").String("custom_action_config") |