CMake: use more conventional checks that libraries were found

The method of checking the library was found cause an undefined
variable warning when it was found.
This commit is contained in:
Campbell Barton 2023-08-17 11:53:52 +10:00
parent 130af96e6b
commit 72bdcb4e25
3 changed files with 3 additions and 3 deletions

View File

@ -59,7 +59,7 @@ FIND_LIBRARY(BROTLI_LIBRARY_DEC
)
IF(${BROTLI_LIBRARY_COMMON_NOTFOUND} or ${BROTLI_LIBRARY_DEC_NOTFOUND})
IF((NOT BROTLI_LIBRARY_COMMON) OR (NOT BROTLI_LIBRARY_DEC))
set(BROTLI_FOUND FALSE)
ELSE()
# handle the QUIETLY and REQUIRED arguments and set BROTLI_FOUND to TRUE if

View File

@ -52,7 +52,7 @@ FIND_LIBRARY(USD_LIBRARY
DOC "Universal Scene Description (USD) monolithic library"
)
IF(${USD_LIBRARY_NOTFOUND})
IF(NOT USD_LIBRARY)
set(USD_FOUND FALSE)
ELSE()
# handle the QUIETLY and REQUIRED arguments and set USD_FOUND to TRUE if

View File

@ -59,7 +59,7 @@ FOREACH(COMPONENT ${_webp_FIND_COMPONENTS})
LIST(APPEND _webp_LIBRARIES "${WEBP_${UPPERCOMPONENT}_LIBRARY}")
ENDFOREACH()
IF(${WEBP_WEBP_LIBRARY_NOTFOUND})
IF(NOT WEBP_WEBP_LIBRARY)
set(WEBP_FOUND FALSE)
ELSE()
# handle the QUIETLY and REQUIRED arguments and set WEBP_FOUND to TRUE if