CPack: add CPACK_THREADS variable to control compression threads

This allows setting how many threads the compressor will use.
Currently only implemented for XZ when using system's lzma library.

Fixes: #21715
This commit is contained in:
Rodolfo Lima
2021-01-18 19:28:46 +01:00
parent bcdb5b52a0
commit bdf30bdad8
12 changed files with 83 additions and 9 deletions
+2 -1
View File
@@ -54,7 +54,8 @@ public:
/** Construct with output stream to which to write archive. */
cmArchiveWrite(std::ostream& os, Compress c = CompressNone,
std::string const& format = "paxr", int compressionLevel = 0);
std::string const& format = "paxr", int compressionLevel = 0,
int numThreads = 1);
~cmArchiveWrite();