Log debug build status and warn when running benchmarks

Log whether the starting instance of bitcoin core is a debug or release
build (--enable-debug).

Also warn when running the benchmarks with a debug build, to prevent
mistakes comparing debug to non-debug results.
This commit is contained in:
Wladimir J. van der Laan
2018-01-16 11:48:33 +01:00
parent 66e3af709d
commit 0c74e2e890
2 changed files with 10 additions and 1 deletions

View File

@@ -808,7 +808,13 @@ void InitLogging()
fLogIPs = gArgs.GetBoolArg("-logips", DEFAULT_LOGIPS);
LogPrintf("\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n");
LogPrintf("Bitcoin version %s\n", FormatFullVersion());
std::string version_string = FormatFullVersion();
#ifdef DEBUG
version_string += " (debug build)";
#else
version_string += " (release build)";
#endif
LogPrintf("Bitcoin version %s\n", version_string);
}
namespace { // Variables internal to initialization process only