Revert "[clang][test] Disallow using the default module cache path in lit tests"

This reverts commit d96f526196.

Some systems do not support `env -u`.
This commit is contained in:
Ben Langmuir 2022-09-12 13:10:22 -07:00
parent e6aebff674
commit 4a72459ed6
3 changed files with 2 additions and 6 deletions

View File

@ -1,4 +1,4 @@
// RUN: env -u CLANG_MODULE_CACHE_PATH %clang -fmodules -### %s 2>&1 | FileCheck %s -check-prefix=CHECK-DEFAULT
// RUN: %clang -fmodules -### %s 2>&1 | FileCheck %s -check-prefix=CHECK-DEFAULT
// CHECK-DEFAULT: -fmodules-cache-path={{.*}}clang{{[/\\]+}}ModuleCache
// RUN: env CLANG_MODULE_CACHE_PATH=/dev/null \

View File

@ -1,4 +1,4 @@
// RUN: env -u CLANG_MODULE_CACHE_PATH %clang -fmodules -fimplicit-module-maps %s -### 2>&1 | FileCheck -check-prefix CHECK-NO_MODULE_CACHE %s
// RUN: %clang -fmodules -fimplicit-module-maps %s -### 2>&1 | FileCheck -check-prefix CHECK-NO_MODULE_CACHE %s
// RUN: %clang -fmodules -fimplicit-module-maps -fmodules-cache-path=blarg %s -### 2>&1 | FileCheck -check-prefix CHECK-WITH_MODULE_CACHE %s
// CHECK-NO_MODULE_CACHE: {{clang.*"-fmodules-cache-path=.*ModuleCache"}}

View File

@ -495,10 +495,6 @@ class LLVMConfig(object):
self.clear_environment(possibly_dangerous_env_vars)
# Make the default module cache path invalid so that tests are forced to
# provide a cache path if they use implicit modules.
self.with_environment('CLANG_MODULE_CACHE_PATH', '/dev/null')
# Tweak the PATH to include the tools dir and the scripts dir.
# Put Clang first to avoid LLVM from overriding out-of-tree clang
# builds.