OLD | NEW |
1 # Copyright (c) 2012 Google Inc. All rights reserved. | 1 # Copyright (c) 2012 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 copy | 5 import copy |
6 import gyp | 6 import gyp |
7 import gyp.common | 7 import gyp.common |
8 import gyp.msvs_emulation | 8 import gyp.msvs_emulation |
9 import gyp.MSVSVersion | 9 import gyp.MSVSVersion |
10 import gyp.system_test | 10 import gyp.system_test |
(...skipping 720 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
731 self.GypPathToNinja)]) | 731 self.GypPathToNinja)]) |
732 | 732 |
733 include_dirs = config.get('include_dirs', []) | 733 include_dirs = config.get('include_dirs', []) |
734 if self.flavor == 'win': | 734 if self.flavor == 'win': |
735 include_dirs = self.msvs_settings.AdjustIncludeDirs(include_dirs, | 735 include_dirs = self.msvs_settings.AdjustIncludeDirs(include_dirs, |
736 config_name) | 736 config_name) |
737 self.WriteVariableList('includes', | 737 self.WriteVariableList('includes', |
738 [QuoteShellArgument('-I' + self.GypPathToNinja(i), self.flavor) | 738 [QuoteShellArgument('-I' + self.GypPathToNinja(i), self.flavor) |
739 for i in include_dirs]) | 739 for i in include_dirs]) |
740 | 740 |
| 741 library_dirs = config.get('library_dirs', []) |
| 742 if self.flavor == 'win': |
| 743 library_dirs = self.msvs_settings.AdjustLibraryDirs(library_dirs, |
| 744 config_name) |
| 745 self.WriteVariableList('libs', |
| 746 [QuoteShellArgument('-L' + self.GypPathToNinja(l), self.flavor) |
| 747 for l in library_dirs]) |
| 748 |
741 pch_commands = precompiled_header.GetPchBuildCommands() | 749 pch_commands = precompiled_header.GetPchBuildCommands() |
742 if self.flavor == 'mac': | 750 if self.flavor == 'mac': |
743 self.WriteVariableList('cflags_pch_c', | 751 self.WriteVariableList('cflags_pch_c', |
744 [precompiled_header.GetInclude('c')]) | 752 [precompiled_header.GetInclude('c')]) |
745 self.WriteVariableList('cflags_pch_cc', | 753 self.WriteVariableList('cflags_pch_cc', |
746 [precompiled_header.GetInclude('cc')]) | 754 [precompiled_header.GetInclude('cc')]) |
747 self.WriteVariableList('cflags_pch_objc', | 755 self.WriteVariableList('cflags_pch_objc', |
748 [precompiled_header.GetInclude('m')]) | 756 [precompiled_header.GetInclude('m')]) |
749 self.WriteVariableList('cflags_pch_objcc', | 757 self.WriteVariableList('cflags_pch_objcc', |
750 [precompiled_header.GetInclude('mm')]) | 758 [precompiled_header.GetInclude('mm')]) |
(...skipping 877 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1628 | 1636 |
1629 user_config = params.get('generator_flags', {}).get('config', None) | 1637 user_config = params.get('generator_flags', {}).get('config', None) |
1630 if user_config: | 1638 if user_config: |
1631 GenerateOutputForConfig(target_list, target_dicts, data, params, | 1639 GenerateOutputForConfig(target_list, target_dicts, data, params, |
1632 user_config) | 1640 user_config) |
1633 else: | 1641 else: |
1634 config_names = target_dicts[target_list[0]]['configurations'].keys() | 1642 config_names = target_dicts[target_list[0]]['configurations'].keys() |
1635 for config_name in config_names: | 1643 for config_name in config_names: |
1636 GenerateOutputForConfig(target_list, target_dicts, data, params, | 1644 GenerateOutputForConfig(target_list, target_dicts, data, params, |
1637 config_name) | 1645 config_name) |
OLD | NEW |