Chromium Code Reviews

Side by Side Diff: pydir/szbuild_spec2k.py

Issue 1407063002: Subzero. Misc ARM32 bugfixes. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Addresses comments. Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff |
« no previous file with comments | « pydir/szbuild.py ('k') | src/IceCfg.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python2 1 #!/usr/bin/env python2
2 2
3 import argparse 3 import argparse
4 import os 4 import os
5 import sys 5 import sys
6 6
7 import szbuild 7 import szbuild
8 8
9 from utils import FindBaseNaCl 9 from utils import FindBaseNaCl
10 10
(...skipping 15 matching lines...)
26 26
27 argparser = argparse.ArgumentParser(description=main.__doc__) 27 argparser = argparse.ArgumentParser(description=main.__doc__)
28 szbuild.AddOptionalArgs(argparser) 28 szbuild.AddOptionalArgs(argparser)
29 argparser.add_argument('comps', nargs='*', default=components) 29 argparser.add_argument('comps', nargs='*', default=components)
30 args = argparser.parse_args() 30 args = argparser.parse_args()
31 bad = set(args.comps) - set(components) 31 bad = set(args.comps) - set(components)
32 if bad: 32 if bad:
33 print 'Unknown component{s}: '.format(s='s' if len(bad) > 1 else '') + \ 33 print 'Unknown component{s}: '.format(s='s' if len(bad) > 1 else '') + \
34 ' '.join(x for x in bad) 34 ' '.join(x for x in bad)
35 sys.exit(1) 35 sys.exit(1)
36 suffix = 'pnacl.opt.x8632' if args.sandbox else 'gcc.opt.x8632' 36 suffix = (
37 'pnacl.opt.{target}' if args.sandbox else 'gcc.opt.{target}').format(
38 target=args.target);
37 for comp in args.comps: 39 for comp in args.comps:
38 name = os.path.splitext(comp)[1] or comp 40 name = os.path.splitext(comp)[1] or comp
39 if name[0] == '.': 41 if name[0] == '.':
40 name = name[1:] 42 name = name[1:]
41 szbuild.ProcessPexe(args, 43 szbuild.ProcessPexe(args,
42 ('{root}/tests/spec2k/{comp}/' + 44 ('{root}/tests/spec2k/{comp}/' +
43 '{name}.opt.stripped.pexe' 45 '{name}.opt.stripped.pexe'
44 ).format(root=nacl_root, comp=comp, name=name), 46 ).format(root=nacl_root, comp=comp, name=name),
45 ('{root}/tests/spec2k/{comp}/' + 47 ('{root}/tests/spec2k/{comp}/' +
46 '{name}.{suffix}' 48 '{name}.{suffix}'
47 ).format(root=nacl_root, comp=comp, name=name, 49 ).format(root=nacl_root, comp=comp, name=name,
48 suffix=suffix)) 50 suffix=suffix))
49 51
50 if __name__ == '__main__': 52 if __name__ == '__main__':
51 main() 53 main()
OLDNEW
« no previous file with comments | « pydir/szbuild.py ('k') | src/IceCfg.cpp » ('j') | no next file with comments »

Powered by Google App Engine