Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(200)

Side by Side Diff: build/detect_v8_host_arch.py

Issue 371923006: Add mips64 port. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Makefile ('k') | build/standalone.gypi » ('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 python 1 #!/usr/bin/env python
2 # Copyright 2014 the V8 project authors. All rights reserved. 2 # Copyright 2014 the V8 project authors. All rights reserved.
3 # Redistribution and use in source and binary forms, with or without 3 # Redistribution and use in source and binary forms, with or without
4 # modification, are permitted provided that the following conditions are 4 # modification, are permitted provided that the following conditions are
5 # met: 5 # met:
6 # 6 #
7 # * Redistributions of source code must retain the above copyright 7 # * Redistributions of source code must retain the above copyright
8 # notice, this list of conditions and the following disclaimer. 8 # notice, this list of conditions and the following disclaimer.
9 # * Redistributions in binary form must reproduce the above 9 # * Redistributions in binary form must reproduce the above
10 # copyright notice, this list of conditions and the following 10 # copyright notice, this list of conditions and the following
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 44
45 # Convert machine type to format recognized by gyp. 45 # Convert machine type to format recognized by gyp.
46 if re.match(r'i.86', host_arch) or host_arch == 'i86pc': 46 if re.match(r'i.86', host_arch) or host_arch == 'i86pc':
47 host_arch = 'ia32' 47 host_arch = 'ia32'
48 elif host_arch in ['x86_64', 'amd64']: 48 elif host_arch in ['x86_64', 'amd64']:
49 host_arch = 'x64' 49 host_arch = 'x64'
50 elif host_arch.startswith('arm'): 50 elif host_arch.startswith('arm'):
51 host_arch = 'arm' 51 host_arch = 'arm'
52 elif host_arch == 'aarch64': 52 elif host_arch == 'aarch64':
53 host_arch = 'arm64' 53 host_arch = 'arm64'
54 elif host_arch == 'mips64':
55 host_arch = 'mips64el'
54 elif host_arch.startswith('mips'): 56 elif host_arch.startswith('mips'):
55 host_arch = 'mipsel' 57 host_arch = 'mipsel'
56 58
57 # platform.machine is based on running kernel. It's possible to use 64-bit 59 # platform.machine is based on running kernel. It's possible to use 64-bit
58 # kernel with 32-bit userland, e.g. to give linker slightly more memory. 60 # kernel with 32-bit userland, e.g. to give linker slightly more memory.
59 # Distinguish between different userland bitness by querying 61 # Distinguish between different userland bitness by querying
60 # the python binary. 62 # the python binary.
61 if host_arch == 'x64' and platform.architecture()[0] == '32bit': 63 if host_arch == 'x64' and platform.architecture()[0] == '32bit':
62 host_arch = 'ia32' 64 host_arch = 'ia32'
63 65
64 return host_arch 66 return host_arch
65 67
66 if __name__ == '__main__': 68 if __name__ == '__main__':
67 sys.exit(main()) 69 sys.exit(main())
OLDNEW
« no previous file with comments | « Makefile ('k') | build/standalone.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698