Merge xmrig v6.7.1 into master
This commit is contained in:
commit
3a7eb49630
13 changed files with 527 additions and 441 deletions
|
@ -1,6 +1,6 @@
|
|||
/* XMRig
|
||||
* Copyright (c) 2018-2020 SChernykh <https://github.com/SChernykh>
|
||||
* Copyright (c) 2016-2020 XMRig <https://github.com/xmrig>, <support@xmrig.com>
|
||||
* Copyright (c) 2018-2021 SChernykh <https://github.com/SChernykh>
|
||||
* Copyright (c) 2016-2021 XMRig <https://github.com/xmrig>, <support@xmrig.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
@ -59,6 +59,11 @@ static void createVariables()
|
|||
variables.insert({ "XMRIG_HOME_DIR", Process::location(Process::HomeLocation) });
|
||||
variables.insert({ "XMRIG_TEMP_DIR", Process::location(Process::TempLocation) });
|
||||
variables.insert({ "XMRIG_DATA_DIR", Process::location(Process::DataLocation) });
|
||||
|
||||
String hostname = "HOSTNAME";
|
||||
if (!getenv(hostname)) {
|
||||
variables.insert({ std::move(hostname), Env::hostname() });
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -76,7 +76,12 @@ public:
|
|||
XMRIG_DISABLE_COPY_MOVE_DEFAULT(BasePrivate)
|
||||
|
||||
|
||||
inline BasePrivate(Process *process) : config(load(process)) {}
|
||||
inline BasePrivate(Process *process)
|
||||
{
|
||||
Log::init();
|
||||
|
||||
config = load(process);
|
||||
}
|
||||
|
||||
|
||||
inline ~BasePrivate()
|
||||
|
@ -166,7 +171,7 @@ private:
|
|||
xmrig::Base::Base(Process *process)
|
||||
: d_ptr(new BasePrivate(process))
|
||||
{
|
||||
Log::init();
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -126,7 +126,8 @@ void xmrig::BenchClient::onBenchDone(uint64_t result, uint64_t diff, uint64_t ts
|
|||
const uint64_t ref = referenceHash();
|
||||
const char *color = ref ? ((result == ref) ? GREEN_BOLD_S : RED_BOLD_S) : BLACK_BOLD_S;
|
||||
|
||||
LOG_NOTICE("%s " WHITE_BOLD("benchmark finished in ") CYAN_BOLD("%.3f seconds") WHITE_BOLD_S " hash sum = " CLEAR "%s%016" PRIX64 CLEAR, tag(), static_cast<double>(ts - m_readyTime) / 1000.0, color, result);
|
||||
const double dt = static_cast<int64_t>(ts - m_readyTime) / 1000.0;
|
||||
LOG_NOTICE("%s " WHITE_BOLD("benchmark finished in ") CYAN_BOLD("%.3f seconds (%.1f h/s)") WHITE_BOLD_S " hash sum = " CLEAR "%s%016" PRIX64 CLEAR, tag(), dt, BenchState::size() / dt, color, result);
|
||||
|
||||
if (m_token.isEmpty()) {
|
||||
printExit();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue