| OLD | NEW |
| 1 # Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 # 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 |
| 3 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 4 | 5 |
| 5 # TODO(slightlyoff): move to using shared version of this script. | 6 # TODO(slightlyoff): move to using shared version of this script. |
| 6 | 7 |
| 7 '''This script makes it easy to combine libs and object files to a new lib, | 8 '''This script makes it easy to combine libs and object files to a new lib, |
| 8 optionally removing some of the object files in the input libs by regular | 9 optionally removing some of the object files in the input libs by regular |
| 9 expression matching. | 10 expression matching. |
| 10 For usage information, run the script with a --help argument. | 11 For usage information, run the script with a --help argument. |
| 11 ''' | 12 ''' |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 remove_re = None | 102 remove_re = None |
| 102 | 103 |
| 103 if sys.platform != 'win32' and sys.platform != 'cygwin': | 104 if sys.platform != 'win32' and sys.platform != 'cygwin': |
| 104 parser.error('this script only works on Windows for now') | 105 parser.error('this script only works on Windows for now') |
| 105 | 106 |
| 106 # If this is set, we can't capture lib.exe's output. | 107 # If this is set, we can't capture lib.exe's output. |
| 107 if 'VS_UNICODE_OUTPUT' in os.environ: | 108 if 'VS_UNICODE_OUTPUT' in os.environ: |
| 108 del os.environ['VS_UNICODE_OUTPUT'] | 109 del os.environ['VS_UNICODE_OUTPUT'] |
| 109 | 110 |
| 110 CombineLibraries(output, remove_re, args) | 111 CombineLibraries(output, remove_re, args) |
| 112 return 0 |
| 111 | 113 |
| 112 | 114 |
| 113 if __name__ == '__main__': | 115 if __name__ == '__main__': |
| 114 Main() | 116 sys.exit(Main()) |
| OLD | NEW |