OLD | NEW |
1 # Copyright (c) 2013 Google Inc. All rights reserved. | 1 # Copyright (c) 2013 Google Inc. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import collections | 5 import collections |
6 import copy | 6 import copy |
7 import hashlib | 7 import hashlib |
8 import json | 8 import json |
9 import multiprocessing | 9 import multiprocessing |
10 import os.path | 10 import os.path |
(...skipping 1077 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1088 | 1088 |
1089 self.WriteVariableList(ninja_file, 'libs', library_dirs + libraries) | 1089 self.WriteVariableList(ninja_file, 'libs', library_dirs + libraries) |
1090 | 1090 |
1091 linked_binary = output | 1091 linked_binary = output |
1092 | 1092 |
1093 if command in ('solink', 'solink_module'): | 1093 if command in ('solink', 'solink_module'): |
1094 extra_bindings.append(('soname', os.path.split(output)[1])) | 1094 extra_bindings.append(('soname', os.path.split(output)[1])) |
1095 extra_bindings.append(('lib', | 1095 extra_bindings.append(('lib', |
1096 gyp.common.EncodePOSIXShellArgument(output))) | 1096 gyp.common.EncodePOSIXShellArgument(output))) |
1097 if self.flavor != 'win': | 1097 if self.flavor != 'win': |
1098 link_file_list = output + '.rsp' | 1098 link_file_list = output |
1099 if self.is_mac_bundle: | 1099 if self.is_mac_bundle: |
1100 # 'Dependency Framework.framework/Versions/A/Dependency Framework' -> | 1100 # 'Dependency Framework.framework/Versions/A/Dependency Framework' -> |
1101 # 'Dependency Framework.framework.rsp' | 1101 # 'Dependency Framework.framework.rsp' |
1102 link_file_list = self.xcode_settings.GetWrapperName() + '.rsp' | 1102 link_file_list = self.xcode_settings.GetWrapperName() |
| 1103 if arch: |
| 1104 link_file_list += '.' + arch |
| 1105 link_file_list += '.rsp' |
1103 # If an rspfile contains spaces, ninja surrounds the filename with | 1106 # If an rspfile contains spaces, ninja surrounds the filename with |
1104 # quotes around it and then passes it to open(), creating a file with | 1107 # quotes around it and then passes it to open(), creating a file with |
1105 # quotes in its name (and when looking for the rsp file, the name | 1108 # quotes in its name (and when looking for the rsp file, the name |
1106 # makes it through bash which strips the quotes) :-/ | 1109 # makes it through bash which strips the quotes) :-/ |
1107 link_file_list = link_file_list.replace(' ', '_') | 1110 link_file_list = link_file_list.replace(' ', '_') |
1108 extra_bindings.append( | 1111 extra_bindings.append( |
1109 ('link_file_list', | 1112 ('link_file_list', |
1110 gyp.common.EncodePOSIXShellArgument(link_file_list))) | 1113 gyp.common.EncodePOSIXShellArgument(link_file_list))) |
1111 if self.flavor == 'win': | 1114 if self.flavor == 'win': |
1112 extra_bindings.append(('binary', output)) | 1115 extra_bindings.append(('binary', output)) |
(...skipping 1070 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2183 arglists.append( | 2186 arglists.append( |
2184 (target_list, target_dicts, data, params, config_name)) | 2187 (target_list, target_dicts, data, params, config_name)) |
2185 pool.map(CallGenerateOutputForConfig, arglists) | 2188 pool.map(CallGenerateOutputForConfig, arglists) |
2186 except KeyboardInterrupt, e: | 2189 except KeyboardInterrupt, e: |
2187 pool.terminate() | 2190 pool.terminate() |
2188 raise e | 2191 raise e |
2189 else: | 2192 else: |
2190 for config_name in config_names: | 2193 for config_name in config_names: |
2191 GenerateOutputForConfig(target_list, target_dicts, data, params, | 2194 GenerateOutputForConfig(target_list, target_dicts, data, params, |
2192 config_name) | 2195 config_name) |
OLD | NEW |