| 1 | config.suffixes = ['.c', '.cpp', '.h', '.m', '.mm', '.S', '.s', '.f90', '.f95', |
| 2 | '.cu', '.rs', '.cl', '.hip'] |
| 3 | config.substitutions = list(config.substitutions) |
| 4 | config.substitutions.insert(0, |
| 5 | ('%clang_cc1', |
| 6 | """*** Do not use 'clang -cc1' in Driver tests. ***""") ) |
| 7 | |
| 8 | # Remove harmful environmental variables for clang Driver tests. |
| 9 | # Some might be useful for other tests so they are only removed here. |
| 10 | driver_overwrite_env_vars = ['MACOSX_DEPLOYMENT_TARGET', |
| 11 | 'IPHONEOS_DEPLOYMENT_TARGET', |
| 12 | 'SDKROOT', 'CCC_OVERRIDE_OPTIONS', |
| 13 | 'CC_PRINT_OPTIONS', 'CC_PRINT_HEADERS', |
| 14 | 'CC_LOG_DIAGNOSTICS'] |
| 15 | |
| 16 | for name in driver_overwrite_env_vars: |
| 17 | if name in config.environment: |
| 18 | del config.environment[name] |
| 19 | |