From bcd27ca2598e488c515441cc22e3f8c3993393bc Mon Sep 17 00:00:00 2001 From: XMRig Date: Tue, 18 Sep 2018 04:04:25 +0300 Subject: [PATCH] Sync changes. --- src/common/config/CommonConfig.cpp | 18 +++++++++++++++++- src/common/interfaces/IConfig.h | 18 +++++++++++------- 2 files changed, 28 insertions(+), 8 deletions(-) diff --git a/src/common/config/CommonConfig.cpp b/src/common/config/CommonConfig.cpp index b39e0e2f..b70d5e3d 100644 --- a/src/common/config/CommonConfig.cpp +++ b/src/common/config/CommonConfig.cpp @@ -39,6 +39,20 @@ #endif +#ifdef XMRIG_AMD_PROJECT +# if defined(__APPLE__) +# include +# else +# include "3rdparty/CL/cl.h" +# endif +#endif + + +#ifdef XMRIG_NVIDIA_PROJECT +# include "nvidia/cryptonight.h" +#endif + + #include "common/config/CommonConfig.h" #include "common/log/Log.h" #include "donate.h" @@ -154,6 +168,9 @@ void xmrig::CommonConfig::printVersions() const char *ocl = "0.0"; # endif int length = snprintf(buf, sizeof buf, "OpenCL/%s ", ocl); +# elif defined(XMRIG_NVIDIA_PROJECT) + const int cudaVersion = cuda_get_runtime_version(); + int length = snprintf(buf, sizeof buf, "CUDA/%d.%d ", cudaVersion / 1000, cudaVersion % 100); # else memset(buf, 0, 16); int length = 0; @@ -170,7 +187,6 @@ void xmrig::CommonConfig::printVersions() length += snprintf(buf + length, (sizeof buf) - length, "microhttpd/%s ", MHD_get_version()); # endif - Log::i()->text(isColors() ? GREEN_BOLD(" * ") WHITE_BOLD("%-13slibuv/%s %s") : " * %-13slibuv/%s %s", "LIBS", uv_version_string(), buf); diff --git a/src/common/interfaces/IConfig.h b/src/common/interfaces/IConfig.h index ece8e3b4..d3593163 100644 --- a/src/common/interfaces/IConfig.h +++ b/src/common/interfaces/IConfig.h @@ -82,13 +82,17 @@ public: HardwareAESKey = 1011, // xmrig amd - OclPlatform = 1400, - OclAffinity = 1401, - OclDevices = 1402, - OclLaunch = 1403, - OclCache = 1404, - OclPrint = 1405, - OclLoader = 1406, + OclPlatformKey = 1400, + OclAffinityKey = 1401, + OclDevicesKey = 1402, + OclLaunchKey = 1403, + OclCacheKey = 1404, + OclPrintKey = 1405, + OclLoaderKey = 1406, + OclSridedIndexKey = 1407, + OclMemChunkKey = 1408, + OclUnrollKey = 1409, + OclCompModeKey = 1410, // xmrig-proxy AccessLogFileKey = 'A',