(source_tree)
| 1673 | extensions_excluded_from_precompile = [".c"] |
| 1674 | |
| 1675 | def DisableForSourceTree(source_tree): |
| 1676 | for source in source_tree: |
| 1677 | if isinstance(source, MSVSProject.Filter): |
| 1678 | DisableForSourceTree(source.contents) |
| 1679 | else: |
| 1680 | _basename, extension = os.path.splitext(source) |
| 1681 | if extension in extensions_excluded_from_precompile: |
| 1682 | for config_name, config in spec["configurations"].items(): |
| 1683 | tool = MSVSProject.Tool( |
| 1684 | "VCCLCompilerTool", |
| 1685 | { |
| 1686 | "UsePrecompiledHeader": "0", |
| 1687 | "ForcedIncludeFiles": "$(NOINHERIT)", |
| 1688 | }, |
| 1689 | ) |
| 1690 | p.AddFileConfig( |
| 1691 | _FixPath(source), |
| 1692 | _ConfigFullName(config_name, config), |
| 1693 | {}, |
| 1694 | tools=[tool], |
| 1695 | ) |
| 1696 | |
| 1697 | # Do nothing if there was no precompiled source. |
| 1698 | if extensions_excluded_from_precompile: |
no test coverage detected