OLD | NEW |
| 1 #!/usr/bin/env python |
| 2 # |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 3 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 5 # found in the LICENSE file. |
4 | 6 |
5 """Converts a given gypi file to a python scope and writes the result to stdout. | 7 """Converts a given gypi file to a python scope and writes the result to stdout. |
6 | 8 |
7 USING THIS SCRIPT IN CHROMIUM | 9 USING THIS SCRIPT IN CHROMIUM |
8 | 10 |
9 Forking Python to run this script in the middle of GN is slow, especially on | 11 Forking Python to run this script in the middle of GN is slow, especially on |
10 Windows, and it makes both the GYP and GN files harder to follow. You can't | 12 Windows, and it makes both the GYP and GN files harder to follow. You can't |
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
182 del data[key] | 184 del data[key] |
183 | 185 |
184 print gn_helpers.ToGNString(data) | 186 print gn_helpers.ToGNString(data) |
185 | 187 |
186 if __name__ == '__main__': | 188 if __name__ == '__main__': |
187 try: | 189 try: |
188 main() | 190 main() |
189 except Exception, e: | 191 except Exception, e: |
190 print str(e) | 192 print str(e) |
191 sys.exit(1) | 193 sys.exit(1) |
OLD | NEW |