From: Viktor Szakats Date: Thu, 18 May 2023 21:02:17 +0000 (+0000) Subject: cmake: avoid `list(PREPEND)` for compatibility X-Git-Tag: curl-8_1_1~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=36e998b18bb0294cef164b2db3791655cfa4440d;p=thirdparty%2Fcurl.git cmake: avoid `list(PREPEND)` for compatibility `list(PREPEND)` requires CMake v3.15, our minimum is v3.7. Ref: https://cmake.org/cmake/help/latest/command/list.html#prepend Regression from 1e3319a167d2f32d295603167486e9e88af9bb4e Reported-by: Keitagit-kun on Github Fixes #11141 Closes #11144 --- diff --git a/CMakeLists.txt b/CMakeLists.txt index a0fe76c244..49a44eabf8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -525,7 +525,7 @@ if(CURL_BROTLI) find_package(Brotli QUIET) if(BROTLI_FOUND) set(HAVE_BROTLI ON) - list(PREPEND CURL_LIBS ${BROTLI_LIBRARIES}) + set(CURL_LIBS "${BROTLI_LIBRARIES};${CURL_LIBS}") # For 'ld' linker. Emulate `list(PREPEND ...)` to stay compatible with