cmake: stop CMake from quietly ignoring missing Brotli

The CMake project was set to `QUIET` for Brotli instead of
`REQUIRED`. This makes builds unexpectedly ignore missing Brotli even
when `CURL_BROTLI` is enabled.

Closes #11376
This commit is contained in:
Michał Petryka 2023-06-22 21:30:43 +02:00 committed by Daniel Stenberg
parent 55dfb9ea47
commit 4e115a19f8
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -524,7 +524,7 @@ endif()
option(CURL_BROTLI "Set to ON to enable building curl with brotli support." OFF)
set(HAVE_BROTLI OFF)
if(CURL_BROTLI)
find_package(Brotli QUIET)
find_package(Brotli REQUIRED)
if(BROTLI_FOUND)
set(HAVE_BROTLI ON)
set(CURL_LIBS "${BROTLI_LIBRARIES};${CURL_LIBS}") # For 'ld' linker. Emulate `list(PREPEND ...)` to stay compatible with <v3.15 CMake.