[PATCH] D79219: [CMake] Simplify CMake handling for zlib

Petr Hosek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 14 20:03:01 PDT 2020


phosek reopened this revision.
phosek added a comment.
This revision is now accepted and ready to land.

I had to revert this change because it broke bots that don't have zlib installed. What I haven't realized is that the shadowed variable will only be accessible from the same file. I could move the logic from `llvm/lib/Support/CMakeLists.txt` into `llvm/cmake/config-ix.cmake`, but that doesn't handle all the other files that need to access that variable, such as all the `*/test/CMakeLists.txt` files. So I don't know if shadowing is the way to go here. Maybe we should set a different internal cached variable (`HAVE_LIBZ`?) and use that to check if zlib is available. What do you think?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D79219/new/

https://reviews.llvm.org/D79219





More information about the llvm-commits mailing list