diff --git a/compiler-rt/test/CMakeLists.txt b/compiler-rt/test/CMakeLists.txt --- a/compiler-rt/test/CMakeLists.txt +++ b/compiler-rt/test/CMakeLists.txt @@ -12,6 +12,9 @@ pythonize_bool(COMPILER_RT_TEST_STANDALONE_BUILD_LIBS) pythonize_bool(LLVM_ENABLE_EXPENSIVE_CHECKS) + +pythonize_bool(ZLIB_FOUND) + configure_compiler_rt_lit_site_cfg( ${CMAKE_CURRENT_SOURCE_DIR}/lit.common.configured.in ${CMAKE_CURRENT_BINARY_DIR}/lit.common.configured) diff --git a/compiler-rt/test/lit.common.cfg.py b/compiler-rt/test/lit.common.cfg.py --- a/compiler-rt/test/lit.common.cfg.py +++ b/compiler-rt/test/lit.common.cfg.py @@ -231,7 +231,7 @@ config.available_features.add("host-byteorder-" + sys.byteorder + "-endian") -if config.have_zlib == "1": +if config.have_zlib: config.available_features.add("zlib") # Use ugly construction to explicitly prohibit "clang", "clang++" etc. diff --git a/compiler-rt/test/lit.common.configured.in b/compiler-rt/test/lit.common.configured.in --- a/compiler-rt/test/lit.common.configured.in +++ b/compiler-rt/test/lit.common.configured.in @@ -65,7 +65,7 @@ else: set_default("target_suffix", "-%s" % config.target_arch) -set_default("have_zlib", "@LLVM_ENABLE_ZLIB@") +set_default("have_zlib", @ZLIB_FOUND_PYBOOL@) set_default("libcxx_used", "@LLVM_LIBCXX_USED@") # LLVM tools dir can be passed in lit parameters, so try to