From 17f3aef08bd21e820d0c58b288dbc7f46b207f79 Mon Sep 17 00:00:00 2001
From: psychocrypt <psychocryptHPC@gmail.com>
Date: Wed, 30 Jan 2019 21:23:25 +0100
Subject: [PATCH] fix compile

- fix broken trutle coin
- fix non cn_gpu algorithms
---
 xmrstak/backend/amd/amd_gpu/opencl/cryptonight.cl      | 9 ++++++---
 xmrstak/backend/amd/amd_gpu/opencl/fast_int_math_v2.cl | 2 +-
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/xmrstak/backend/amd/amd_gpu/opencl/cryptonight.cl b/xmrstak/backend/amd/amd_gpu/opencl/cryptonight.cl
index ea07d6a..5339403 100644
--- a/xmrstak/backend/amd/amd_gpu/opencl/cryptonight.cl
+++ b/xmrstak/backend/amd/amd_gpu/opencl/cryptonight.cl
@@ -347,8 +347,11 @@ XMRSTAK_INCLUDE_JH
 XMRSTAK_INCLUDE_BLAKE256
 //#include "opencl/groestl256.cl"
 XMRSTAK_INCLUDE_GROESTL256
-//#include "opencl/cryptonight_gpu.cl"
-XMRSTAK_INCLUDE_CN_GPU
+
+#if (ALGO == 13)
+	//#include "opencl/cryptonight_gpu.cl"
+	XMRSTAK_INCLUDE_CN_GPU
+#endif
 
 )==="
 R"===(
@@ -789,7 +792,7 @@ __kernel void JOIN(cn1,ALGO) (__global uint4 *Scratchpad, __global ulong *states
         ((uint4 *)a)[0] ^= tmp;
 
 // cryptonight_monero_v8
-#if (ALGO == 11 || ALGO==13)
+#if (ALGO == 11 || ALGO==14)
 #	if defined(__NV_CL_C_VERSION)
 			// flush shuffled data
 			SCRATCHPAD_CHUNK_GLOBAL = *scratchpad_line;
diff --git a/xmrstak/backend/amd/amd_gpu/opencl/fast_int_math_v2.cl b/xmrstak/backend/amd/amd_gpu/opencl/fast_int_math_v2.cl
index 4205a67..93e304a 100644
--- a/xmrstak/backend/amd/amd_gpu/opencl/fast_int_math_v2.cl
+++ b/xmrstak/backend/amd/amd_gpu/opencl/fast_int_math_v2.cl
@@ -4,7 +4,7 @@ R"===(
  */
 
 // cryptonight_monero_v8
-#if(ALGO==11 || ALGO==13)
+#if(ALGO==11 || ALGO==14)
 
 static const __constant uint RCP_C[256] =
 {
-- 
GitLab