Merge "Only copy native binaries on native-bridge configs"

This commit is contained in:
Treehugger Robot 2019-01-25 22:35:58 +00:00 committed by Gerrit Code Review
commit 1d08e2f66e
1 changed files with 5 additions and 0 deletions

View File

@ -570,6 +570,11 @@ func (a *apexBundle) GenerateAndroidBuildActions(ctx android.ModuleContext) {
}
case executableTag:
if cc, ok := child.(*cc.Module); ok {
if !cc.Arch().Native {
// There is only one 'bin' directory so we shouldn't bother copying in
// native-bridge'd binaries and only use main ones.
return true
}
fileToCopy, dirInApex := getCopyManifestForExecutable(cc)
filesInfo = append(filesInfo, apexFile{fileToCopy, depName, cc.Arch().ArchType, dirInApex, nativeExecutable, cc})
return true