diff options
author | Jiyong Park <jiyong@google.com> | 2018-02-01 00:54:12 +0900 |
---|---|---|
committer | Jiyong Park <jiyong@google.com> | 2018-05-15 16:27:12 +0900 |
commit | f9332f1c866ce87b5a8603256cd1a606c4753d5f (patch) | |
tree | 8d6e2a05dc82d7d31a8c89142ff2d0b47713dbfa /cc/binary.go | |
parent | ff9d8911f68bcfce038d833522d8a41d7f22fe35 (diff) | |
download | build_soong-f9332f1c866ce87b5a8603256cd1a606c4753d5f.tar.gz build_soong-f9332f1c866ce87b5a8603256cd1a606c4753d5f.tar.bz2 build_soong-f9332f1c866ce87b5a8603256cd1a606c4753d5f.zip |
Support recovery and recovery_available
`recovery: true` installs a module to the recovery partition.
`recovery_available: true` makes a module to be available to other
`recovery:true` or `recovery_available: true` modules.
These to are very similar to vendor, vendor_available properties, except
for the target partition.
Bug: 67916654
Bug: 64960723
Test: m -j, toybox_recovery is installed to the recovery/root/sbin
Change-Id: Iaebe0593de16c69fa70de251a61f4d018a251509
Diffstat (limited to 'cc/binary.go')
-rw-r--r-- | cc/binary.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/cc/binary.go b/cc/binary.go index 9e7b70b2..00fda064 100644 --- a/cc/binary.go +++ b/cc/binary.go @@ -353,6 +353,11 @@ func (binary *binaryDecorator) link(ctx ModuleContext, } func (binary *binaryDecorator) install(ctx ModuleContext, file android.Path) { + // <recovery>/bin is a symlink to /system/bin. Recovery binaries are all in /sbin. + if ctx.inRecovery() { + binary.baseInstaller.dir = "sbin" + } + binary.baseInstaller.install(ctx, file) for _, symlink := range binary.Properties.Symlinks { binary.symlinks = append(binary.symlinks, |