mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-02 04:09:33 -05:00
Autogen: cmQtAutoRcc settings hash computation optimizations
This commit is contained in:
+15
-9
@@ -13,6 +13,8 @@
|
|||||||
#include "cmSystemTools.h"
|
#include "cmSystemTools.h"
|
||||||
#include "cm_string_view.hxx"
|
#include "cm_string_view.hxx"
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
|
|
||||||
cmQtAutoRcc::cmQtAutoRcc() = default;
|
cmQtAutoRcc::cmQtAutoRcc() = default;
|
||||||
|
|
||||||
cmQtAutoRcc::~cmQtAutoRcc() = default;
|
cmQtAutoRcc::~cmQtAutoRcc() = default;
|
||||||
@@ -164,15 +166,19 @@ bool cmQtAutoRcc::SettingsFileRead()
|
|||||||
{
|
{
|
||||||
// Compose current settings strings
|
// Compose current settings strings
|
||||||
{
|
{
|
||||||
cmCryptoHash crypt(cmCryptoHash::AlgoSHA256);
|
cmCryptoHash cryptoHash(cmCryptoHash::AlgoSHA256);
|
||||||
std::string const sep(" ~~~ ");
|
auto cha = [&cryptoHash](cm::string_view value) {
|
||||||
{
|
cryptoHash.Append(value);
|
||||||
std::string str =
|
cryptoHash.Append(";");
|
||||||
cmStrCat(RccExecutable_, sep, cmJoin(RccListOptions_, ";"), sep,
|
};
|
||||||
QrcFile_, sep, RccPathChecksum_, sep, RccFileName_, sep,
|
cha(RccExecutable_);
|
||||||
cmJoin(Options_, ";"), sep, cmJoin(Inputs_, ";"), sep);
|
std::for_each(RccListOptions_.begin(), RccListOptions_.end(), cha);
|
||||||
SettingsString_ = crypt.HashString(str);
|
cha(QrcFile_);
|
||||||
}
|
cha(RccPathChecksum_);
|
||||||
|
cha(RccFileName_);
|
||||||
|
std::for_each(Options_.begin(), Options_.end(), cha);
|
||||||
|
std::for_each(Inputs_.begin(), Inputs_.end(), cha);
|
||||||
|
SettingsString_ = cryptoHash.FinalizeHex();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Make sure the settings file exists
|
// Make sure the settings file exists
|
||||||
|
|||||||
Reference in New Issue
Block a user