dependencies/zlib: Fix header detection
has_header returns a tuple of (found: bool, cached: bool), so `if has_header` will always return true because the tuple is non-empty. We need to check if the found value is true or not.
This commit is contained in:
parent
7d11d7cf68
commit
cb6ccf2632
|
@ -480,7 +480,7 @@ class ZlibSystemDependency(ExternalDependency):
|
|||
for lib in libs:
|
||||
l = self.clib_compiler.find_library(lib, environment, [])
|
||||
h = self.clib_compiler.has_header('zlib.h', '', environment, dependencies=[self])
|
||||
if l and h:
|
||||
if l and h[0]:
|
||||
self.is_found = True
|
||||
self.link_args = l
|
||||
break
|
||||
|
|
Loading…
Reference in New Issue