Set 'deflate' to DEFLATE_NAMES, instead of 'libdeflate'

'lib' will be automatically added as a prefix while doing find_library()
This commit is contained in:
Lemures Lemniscati 2020-12-13 06:30:46 +09:00
parent 9a935c7e23
commit dd38d7cb1b

View File

@ -464,7 +464,7 @@ option(libdeflate "use libdeflate (optional for faster Deflate support, still re
if (libdeflate)
set(DEFLATE_FOUND 0)
find_path(DEFLATE_INCLUDE_DIR libdeflate.h)
set(DEFLATE_NAMES ${DEFLATE_NAMES} libdeflate)
set(DEFLATE_NAMES ${DEFLATE_NAMES} deflate)
find_library(DEFLATE_LIBRARY NAMES ${DEFLATE_NAMES})
if (DEFLATE_INCLUDE_DIR AND DEFLATE_LIBRARY)
set(DEFLATE_FOUND 1)