OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2011 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 # IMPORTANT NOTE: If you make local mods to this file, you must run: | 6 # IMPORTANT NOTE: If you make local mods to this file, you must run: |
7 # % tools/llvm/utman.sh driver | 7 # % tools/llvm/utman.sh driver |
8 # in order for them to take effect in the scons build. This command | 8 # in order for them to take effect in the scons build. This command |
9 # updates the copy in the toolchain/ tree. | 9 # updates the copy in the toolchain/ tree. |
10 # | 10 # |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 ( ('(-Ttext)','(.*)'), "env.append('LD_FLAGS', $0, $1)"), | 144 ( ('(-Ttext)','(.*)'), "env.append('LD_FLAGS', $0, $1)"), |
145 ( ('(-Ttext=.*)'), "env.append('LD_FLAGS', $0)"), | 145 ( ('(-Ttext=.*)'), "env.append('LD_FLAGS', $0)"), |
146 ( ('-T', '(.*)'), "env.set('LD_SCRIPT', $0)"), | 146 ( ('-T', '(.*)'), "env.set('LD_SCRIPT', $0)"), |
147 | 147 |
148 ( ('-e','(.*)'), "env.append('LD_FLAGS', '-e', $0)"), | 148 ( ('-e','(.*)'), "env.append('LD_FLAGS', '-e', $0)"), |
149 ( ('(--section-start)','(.*)'), "env.append('LD_FLAGS', $0, $1)"), | 149 ( ('(--section-start)','(.*)'), "env.append('LD_FLAGS', $0, $1)"), |
150 ( '(-?-soname=.*)', "env.append('LD_FLAGS', $0)"), | 150 ( '(-?-soname=.*)', "env.append('LD_FLAGS', $0)"), |
151 ( ('(-?-soname)', '(.*)'), "env.append('LD_FLAGS', $0, $1)"), | 151 ( ('(-?-soname)', '(.*)'), "env.append('LD_FLAGS', $0, $1)"), |
152 ( '(--eh-frame-hdr)', "env.append('LD_FLAGS', $0)"), | 152 ( '(--eh-frame-hdr)', "env.append('LD_FLAGS', $0)"), |
153 | 153 |
| 154 ( '(--print-gc-sections)', "env.append('LD_FLAGS', $0)"), |
| 155 ( '(-gc-sections)', "env.append('LD_FLAGS', $0)"), |
| 156 |
154 ( '-melf_nacl', "env.set('ARCH', 'X8632')"), | 157 ( '-melf_nacl', "env.set('ARCH', 'X8632')"), |
155 ( ('-m','elf_nacl'), "env.set('ARCH', 'X8632')"), | 158 ( ('-m','elf_nacl'), "env.set('ARCH', 'X8632')"), |
156 ( '-melf64_nacl', "env.set('ARCH', 'X8664')"), | 159 ( '-melf64_nacl', "env.set('ARCH', 'X8664')"), |
157 ( ('-m','elf64_nacl'), "env.set('ARCH', 'X8664')"), | 160 ( ('-m','elf64_nacl'), "env.set('ARCH', 'X8664')"), |
158 ( '-marmelf_nacl', "env.set('ARCH', 'ARM')"), | 161 ( '-marmelf_nacl', "env.set('ARCH', 'ARM')"), |
159 ( ('-m','armelf_nacl'), "env.set('ARCH', 'ARM')"), | 162 ( ('-m','armelf_nacl'), "env.set('ARCH', 'ARM')"), |
160 | 163 |
161 ( ('-?-wrap', '(.+)'), "env.append('WRAP_SYMBOLS', $0)"), | 164 ( ('-?-wrap', '(.+)'), "env.append('WRAP_SYMBOLS', $0)"), |
162 ( ('-?-wrap=(.+)'), "env.append('WRAP_SYMBOLS', $0)"), | 165 ( ('-?-wrap=(.+)'), "env.append('WRAP_SYMBOLS', $0)"), |
163 | 166 |
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
734 elif IsFlag(f): | 737 elif IsFlag(f): |
735 continue | 738 continue |
736 else: | 739 else: |
737 if not os.path.exists(f): | 740 if not os.path.exists(f): |
738 Log.Fatal("Unable to open '%s'", f) | 741 Log.Fatal("Unable to open '%s'", f) |
739 ret.append(f) | 742 ret.append(f) |
740 return ret | 743 return ret |
741 | 744 |
742 if __name__ == "__main__": | 745 if __name__ == "__main__": |
743 DriverMain(main) | 746 DriverMain(main) |
OLD | NEW |