Index: tools/binary_size/diagnose_bloat.py |
diff --git a/tools/binary_size/diagnose_bloat.py b/tools/binary_size/diagnose_bloat.py |
index 37b5e88690d9a7363d0c990e8113dddf15f20e83..dd7109ed67feded2e5ad115f667fb479745d45d9 100755 |
--- a/tools/binary_size/diagnose_bloat.py |
+++ b/tools/binary_size/diagnose_bloat.py |
@@ -233,7 +233,9 @@ class _BuildHelper(object): |
@property |
def size_name(self): |
- return os.path.splitext(os.path.basename(self.main_lib_path))[0] + '.size' |
+ if self.IsLinux(): |
+ return os.path.basename(self.main_lib_path) + '.size' |
+ return self.apk_name + '.size' |
def _SetDefaults(self): |
has_goma_dir = os.path.exists(os.path.join(os.path.expanduser('~'), 'goma')) |
@@ -759,8 +761,10 @@ def main(): |
parser.error('--subrepo doesn\'t work with --cloud') |
subrepo = args.subrepo or _SRC_ROOT |
- _EnsureDirectoryClean(subrepo) |
- _SetRestoreFunc(subrepo) |
+ if not build.IsCloud(): |
+ _EnsureDirectoryClean(subrepo) |
+ _SetRestoreFunc(subrepo) |
+ |
if build.IsLinux(): |
_VerifyUserAccepts('Linux diffs have known deficiencies (crbug/717550).') |