summaryrefslogtreecommitdiffstats
path: root/Source/CPack/cmCPackDebGenerator.cxx
diff options
context:
space:
mode:
authorNils Gladitz <nilsgladitz@gmail.com>2021-04-19 17:37:57 (GMT)
committerBrad King <brad.king@kitware.com>2021-04-22 19:40:13 (GMT)
commitc5c130e675624eef03f5bcaf848810659e205ed2 (patch)
treeab057134a2452170450b06777f0149f1d6d8ad53 /Source/CPack/cmCPackDebGenerator.cxx
parent5380d858ff4cb21ae1a8777a9b721af97f598c37 (diff)
downloadCMake-c5c130e675624eef03f5bcaf848810659e205ed2.zip
CMake-c5c130e675624eef03f5bcaf848810659e205ed2.tar.gz
CMake-c5c130e675624eef03f5bcaf848810659e205ed2.tar.bz2
cmArchiveWrite: Consolidate multiple ways to set thread count
Merge use of SetFilterOption() into more abstract thread count in cmArchiveWrite constructor. libarchive defaulting of threads for threads == 0 seems to be configuration dependent. Preemptively default thread count via std::thread::hardware_concurrency(). Also allow negative values for the thread count in which case the detected hardware concurrency is also used but the given absolute thread count is used as an upper limit.
Diffstat (limited to 'Source/CPack/cmCPackDebGenerator.cxx')
-rw-r--r--Source/CPack/cmCPackDebGenerator.cxx5
1 files changed, 0 insertions, 5 deletions
diff --git a/Source/CPack/cmCPackDebGenerator.cxx b/Source/CPack/cmCPackDebGenerator.cxx
index e7bcfac..0fafd85 100644
--- a/Source/CPack/cmCPackDebGenerator.cxx
+++ b/Source/CPack/cmCPackDebGenerator.cxx
@@ -130,11 +130,6 @@ DebGenerator::DebGenerator(
"Unrecognized number of threads: " << numThreads
<< std::endl);
}
-
- if (this->NumThreads < 0) {
- cmCPackLogger(cmCPackLog::LOG_ERROR,
- "Number of threads cannot be negative" << std::endl);
- }
}
bool DebGenerator::generate() const