diff options
-rwxr-xr-x | scripts/tiny/ksize.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/tiny/ksize.py b/scripts/tiny/ksize.py index bc11919f4b..8316b85cb1 100755 --- a/scripts/tiny/ksize.py +++ b/scripts/tiny/ksize.py | |||
@@ -27,7 +27,7 @@ def usage(): | |||
27 | class Sizes: | 27 | class Sizes: |
28 | def __init__(self, glob): | 28 | def __init__(self, glob): |
29 | self.title = glob | 29 | self.title = glob |
30 | p = Popen("size -t " + str(glob), shell=True, stdout=PIPE, stderr=PIPE) | 30 | p = Popen("size -t " + str(glob), shell=True, stdout=PIPE, stderr=PIPE, universal_newlines=True) |
31 | output = p.communicate()[0].splitlines() | 31 | output = p.communicate()[0].splitlines() |
32 | if len(output) > 2: | 32 | if len(output) > 2: |
33 | sizes = output[-1].split()[0:4] | 33 | sizes = output[-1].split()[0:4] |
@@ -49,14 +49,14 @@ class Report: | |||
49 | path = os.path.dirname(filename) | 49 | path = os.path.dirname(filename) |
50 | 50 | ||
51 | p = Popen("ls " + str(path) + "/*.o | grep -v built-in.o", | 51 | p = Popen("ls " + str(path) + "/*.o | grep -v built-in.o", |
52 | shell=True, stdout=PIPE, stderr=PIPE) | 52 | shell=True, stdout=PIPE, stderr=PIPE, universal_newlines=True) |
53 | glob = ' '.join(p.communicate()[0].splitlines()) | 53 | glob = ' '.join(p.communicate()[0].splitlines()) |
54 | oreport = Report(glob, str(path) + "/*.o") | 54 | oreport = Report(glob, str(path) + "/*.o") |
55 | oreport.sizes.title = str(path) + "/*.o" | 55 | oreport.sizes.title = str(path) + "/*.o" |
56 | r.parts.append(oreport) | 56 | r.parts.append(oreport) |
57 | 57 | ||
58 | if subglob: | 58 | if subglob: |
59 | p = Popen("ls " + subglob, shell=True, stdout=PIPE, stderr=PIPE) | 59 | p = Popen("ls " + subglob, shell=True, stdout=PIPE, stderr=PIPE, universal_newlines=True) |
60 | for f in p.communicate()[0].splitlines(): | 60 | for f in p.communicate()[0].splitlines(): |
61 | path = os.path.dirname(f) | 61 | path = os.path.dirname(f) |
62 | r.parts.append(Report.create(f, path, str(path) + "/*/built-in.o")) | 62 | r.parts.append(Report.create(f, path, str(path) + "/*/built-in.o")) |