diff options
author | Eric Fiselier <eric@efcs.ca> | 2016-12-06 00:01:04 +0000 |
---|---|---|
committer | Eric Fiselier <eric@efcs.ca> | 2016-12-06 00:01:04 +0000 |
commit | 8e27c2b970f065033cc8c9eeecda480049d1edb5 (patch) | |
tree | f3b112c612349f9b069c53c199b3bfabadd0d206 /libcxx/test | |
parent | e1f72557c237420f47b2f31c5bd7529615b78e18 (diff) | |
download | bcm5719-llvm-8e27c2b970f065033cc8c9eeecda480049d1edb5.tar.gz bcm5719-llvm-8e27c2b970f065033cc8c9eeecda480049d1edb5.zip |
Allow enabling/disabling testing with module using env LIBCXX_USE_MODULES=1
The Clang modules implementation breaks enough that libc++ needs an easy way
to enable/disable using modules on the Zorg builders. Editing Zorg itself
requires a buildmaster restart which only happens weekly. This patch
allows LIBCXX_USE_MODULES to be used to enable/disable the feature,
allowing the buildslave to disable it as need be.
llvm-svn: 288736
Diffstat (limited to 'libcxx/test')
-rw-r--r-- | libcxx/test/libcxx/test/config.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libcxx/test/libcxx/test/config.py b/libcxx/test/libcxx/test/config.py index 849b163dcca..f9ab22fe06e 100644 --- a/libcxx/test/libcxx/test/config.py +++ b/libcxx/test/libcxx/test/config.py @@ -736,7 +736,10 @@ class Configuration(object): if platform.system() != 'Darwin': modules_flags += ['-Xclang', '-fmodules-local-submodule-visibility'] supports_modules = self.cxx.hasCompileFlag(modules_flags) - enable_modules = self.get_lit_bool('enable_modules', False) + enable_modules_default = supports_modules and \ + os.environ.get('LIBCXX_USE_MODULES') is not None + enable_modules = self.get_lit_bool('enable_modules', + enable_modules_default) if enable_modules and not supports_modules: self.lit_config.fatal( '-fmodules is enabled but not supported by the compiler') |