CMake/Linux: only link to brotli when using static precompiled libraries

The Brotli library only needs to be explicitly linked when using the
statically linked libraries. When using system libs they're shared, and
the .so loading mechanism takes care of dependencies.
This commit is contained in:
2022-01-25 16:18:53 +01:00
parent 14f6afb090
commit 0477ca75f0

View File

@@ -103,7 +103,9 @@ find_package_wrapper(Zstd REQUIRED)
# FreeType compiled with Brotli compression for woff2.
find_package_wrapper(Freetype REQUIRED)
find_package_wrapper(Brotli REQUIRED)
if(EXISTS ${LIBDIR})
find_package_wrapper(Brotli REQUIRED)
endif()
if(WITH_PYTHON)
# No way to set py35, remove for now.