summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Treehugger Robot <treehugger-gerrit@google.com> 2023-03-21 05:39:54 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2023-03-21 05:39:54 +0000
commit2f1e052266636bc484b7599f3b07d7652758e298 (patch)
treea4460f952a21e04592b3031ad3b6cdffc0749606
parent2204e164426deaeac648722af383ddaa2f4f8cf6 (diff)
parentc1fd399ccd8597f6d150a3385d468aeead42d44d (diff)
Merge "Use installExecutable for cc binaries"
-rw-r--r--cc/binary.go2
-rw-r--r--cc/installer.go4
2 files changed, 5 insertions, 1 deletions
diff --git a/cc/binary.go b/cc/binary.go
index 496c610c2..097f82252 100644
--- a/cc/binary.go
+++ b/cc/binary.go
@@ -512,7 +512,7 @@ func (binary *binaryDecorator) install(ctx ModuleContext, file android.Path) {
}
binary.baseInstaller.subDir = "bootstrap"
}
- binary.baseInstaller.install(ctx, file)
+ binary.baseInstaller.installExecutable(ctx, file)
var preferredArchSymlinkPath android.OptionalPath
for _, symlink := range binary.symlinks {
diff --git a/cc/installer.go b/cc/installer.go
index e2c0e7b8d..716a0dfc6 100644
--- a/cc/installer.go
+++ b/cc/installer.go
@@ -100,6 +100,10 @@ func (installer *baseInstaller) install(ctx ModuleContext, file android.Path) {
installer.path = ctx.InstallFile(installer.installDir(ctx), file.Base(), file)
}
+func (installer *baseInstaller) installExecutable(ctx ModuleContext, file android.Path) {
+ installer.path = ctx.InstallExecutable(installer.installDir(ctx), file.Base(), file)
+}
+
func (installer *baseInstaller) everInstallable() bool {
// Most cc modules are installable.
return true