llvm.org GIT mirror llvm / 33287ae
Revert "[cmake] Use find_package to discover zlib" We are investigating what went wrong. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@316029 91177308-0d34-0410-b5e6-96231b3b80d8 Vassil Vassilev 2 years ago
2 changed file(s) with 2 addition(s) and 5 deletion(s). Raw diff Collapse all Expand all
131131 # like strlen, leading to false positives.
132132 if( NOT PURE_WINDOWS AND NOT LLVM_USE_SANITIZER MATCHES "Memory.*")
133133 if (LLVM_ENABLE_ZLIB)
134 find_package(ZLIB REQUIRED)
135 if (ZLIB_FOUND)
136 set(HAVE_LIBZ 1)
137 endif()
134 check_library_exists(z compress2 "" HAVE_LIBZ)
138135 else()
139136 set(HAVE_LIBZ 0)
140137 endif()
2121 endif()
2222 set(system_libs ${system_libs} ${LLVM_PTHREAD_LIB})
2323 if ( LLVM_ENABLE_ZLIB AND HAVE_LIBZ )
24 set(system_libs ${system_libs} ${ZLIB_LIBRARIES})
24 set(system_libs ${system_libs} z)
2525 endif()
2626 if( UNIX AND NOT (BEOS OR HAIKU) )
2727 set(system_libs ${system_libs} m)