OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # Copyright (c) 2013 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2013 The Native Client Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 """Recipes for PNaCl toolchain packages. | 6 """Recipes for PNaCl toolchain packages. |
7 | 7 |
8 Recipes consist of specially-structured dictionaries, with keys for package | 8 Recipes consist of specially-structured dictionaries, with keys for package |
9 name, type, commands to execute, etc. The structure is documented in the | 9 name, type, commands to execute, etc. The structure is documented in the |
10 PackageBuilder docstring in toolchain_main.py. | 10 PackageBuilder docstring in toolchain_main.py. |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 MINGW_PATH = os.path.join(NACL_DIR, 'mingw32') | 81 MINGW_PATH = os.path.join(NACL_DIR, 'mingw32') |
82 MINGW_VERSION = 'i686-w64-mingw32-4.8.1' | 82 MINGW_VERSION = 'i686-w64-mingw32-4.8.1' |
83 | 83 |
84 CHROME_CLANG = os.path.join(os.path.dirname(NACL_DIR), 'third_party', | 84 CHROME_CLANG = os.path.join(os.path.dirname(NACL_DIR), 'third_party', |
85 'llvm-build', 'Release+Asserts', 'bin', 'clang') | 85 'llvm-build', 'Release+Asserts', 'bin', 'clang') |
86 CHROME_CLANGXX = CHROME_CLANG + '++' | 86 CHROME_CLANGXX = CHROME_CLANG + '++' |
87 | 87 |
88 ALL_ARCHES = ('x86-32', 'x86-64', 'arm', 'mips32', | 88 ALL_ARCHES = ('x86-32', 'x86-64', 'arm', 'mips32', |
89 'x86-32-nonsfi', 'arm-nonsfi') | 89 'x86-32-nonsfi', 'arm-nonsfi') |
90 # MIPS32 doesn't use biased bitcode, and nonsfi targets don't need it. | 90 # MIPS32 doesn't use biased bitcode, and nonsfi targets don't need it. |
91 BITCODE_BIASES = tuple(bias for bias in ('portable', 'x86-32', 'x86-64', 'arm')) | 91 BITCODE_BIASES = tuple(bias for bias in ('le32', 'x86-32', 'x86-64', 'arm')) |
92 | 92 |
93 MAKE_DESTDIR_CMD = ['make', 'DESTDIR=%(abs_output)s'] | 93 MAKE_DESTDIR_CMD = ['make', 'DESTDIR=%(abs_output)s'] |
94 | 94 |
95 def TripleIsWindows(t): | 95 def TripleIsWindows(t): |
96 return fnmatch.fnmatch(t, '*-mingw32*') | 96 return fnmatch.fnmatch(t, '*-mingw32*') |
97 | 97 |
98 def TripleIsCygWin(t): | 98 def TripleIsCygWin(t): |
99 return fnmatch.fnmatch(t, '*-cygwin*') | 99 return fnmatch.fnmatch(t, '*-cygwin*') |
100 | 100 |
101 def TripleIsLinux(t): | 101 def TripleIsLinux(t): |
(...skipping 687 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
789 packages.update(Metadata(rev)) | 789 packages.update(Metadata(rev)) |
790 if pynacl.platform.IsLinux() or pynacl.platform.IsMac(): | 790 if pynacl.platform.IsLinux() or pynacl.platform.IsMac(): |
791 packages.update(pnacl_targetlibs.UnsandboxedIRT( | 791 packages.update(pnacl_targetlibs.UnsandboxedIRT( |
792 'x86-32-%s' % pynacl.platform.GetOS())) | 792 'x86-32-%s' % pynacl.platform.GetOS())) |
793 | 793 |
794 | 794 |
795 tb = toolchain_main.PackageBuilder(packages, | 795 tb = toolchain_main.PackageBuilder(packages, |
796 upload_packages, | 796 upload_packages, |
797 leftover_args) | 797 leftover_args) |
798 tb.Main() | 798 tb.Main() |
OLD | NEW |