| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can b | 2 # Use of this source code is governed by a BSD-style license that can b |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 """Enumerates the BoringSSL source in src/ and generates two gypi files: | 5 """Enumerates the BoringSSL source in src/ and generates two gypi files: |
| 6 boringssl.gypi and boringssl_tests.gypi.""" | 6 boringssl.gypi and boringssl_tests.gypi.""" |
| 7 | 7 |
| 8 import os | 8 import os |
| 9 import subprocess | 9 import subprocess |
| 10 import sys | 10 import sys |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 213 test_name = 'boringssl_%s' % os.path.splitext(os.path.basename(test))[0] | 213 test_name = 'boringssl_%s' % os.path.splitext(os.path.basename(test))[0] |
| 214 test_gypi.write(""" { | 214 test_gypi.write(""" { |
| 215 'target_name': '%s', | 215 'target_name': '%s', |
| 216 'type': 'executable', | 216 'type': 'executable', |
| 217 'dependencies': [ | 217 'dependencies': [ |
| 218 'boringssl.gyp:boringssl', | 218 'boringssl.gyp:boringssl', |
| 219 ], | 219 ], |
| 220 'sources': [ | 220 'sources': [ |
| 221 '%s', | 221 '%s', |
| 222 ], | 222 ], |
| 223 # TODO(davidben): Fix size_t truncations in BoringSSL. |
| 224 # https://crbug.com/429039 |
| 225 'msvs_disabled_warnings': [ 4267, ], |
| 223 },\n""" % (test_name, test)) | 226 },\n""" % (test_name, test)) |
| 224 test_names.append(test_name) | 227 test_names.append(test_name) |
| 225 | 228 |
| 226 test_names.sort() | 229 test_names.sort() |
| 227 | 230 |
| 228 test_gypi.write(""" ], | 231 test_gypi.write(""" ], |
| 229 'variables': { | 232 'variables': { |
| 230 'boringssl_test_targets': [\n""") | 233 'boringssl_test_targets': [\n""") |
| 231 | 234 |
| 232 for test in test_names: | 235 for test in test_names: |
| 233 test_gypi.write(""" '%s',\n""" % test) | 236 test_gypi.write(""" '%s',\n""" % test) |
| 234 | 237 |
| 235 test_gypi.write(' ],\n }\n}\n') | 238 test_gypi.write(' ],\n }\n}\n') |
| 236 | 239 |
| 237 return 0 | 240 return 0 |
| 238 | 241 |
| 239 | 242 |
| 240 if __name__ == '__main__': | 243 if __name__ == '__main__': |
| 241 sys.exit(main()) | 244 sys.exit(main()) |
| OLD | NEW |