mirror of
https://github.com/Kitware/CMake.git
synced 2026-06-24 08:47:59 +00:00
zstd: Enable multithreading support in build within CMake
Since commitcbf71b21b2(cli tar: support multithreading compression, 2025-11-28, v4.3.0-rc1~393^2~1) we offer command-line options to control compression threading. Enable them when used with Zstd. On AIX this causes allocation failures similar to those we avoid via commit1ba3444fd8(libarchive: Limit 7zip and zstd compression level to 6 on AIX, 2025-12-11, v4.3.0-rc1~335^2~1), so leave threading off there pending further investigation. Issue: #27712
This commit is contained in:
@@ -53,4 +53,11 @@ target_compile_definitions(cmzstd PRIVATE
|
||||
ZSTD_DISABLE_ASM=1
|
||||
)
|
||||
|
||||
if(NOT CMAKE_SYSTEM_NAME STREQUAL "AIX")
|
||||
target_compile_definitions(cmzstd PRIVATE
|
||||
# Enable threaded compression.
|
||||
ZSTD_MULTITHREAD
|
||||
)
|
||||
endif()
|
||||
|
||||
install(FILES LICENSE DESTINATION ${CMake_INSTALL_DOC_DIR}/cmzstd)
|
||||
|
||||
Reference in New Issue
Block a user