Description: Fix_Lyra2Z_build_for_cuda_arch_below_50
 The condition is wrong and misses CUDA level 3.7
 .
 nvcc -gencode=arch=compute_30,code=\"sm_30,compute_30\" -gencode=arch=compute_35,code=\"sm_35,compute_35\" -gencode=arch=compute_37,code=\"sm_37,compute_37\" -gencode=arch=compute_50,code=\"sm_50,compute_50\" -gencode=arch=compute_52,code=\"sm_52,compute_52\" -gencode=arch=compute_53,code=\"sm_53,compute_53\" -I/usr/local/cuda/include -I. -O3 -lineno -Xcompiler -Wall -D_FORCE_INLINES -I./compat/jansson --ptxas-options="-v" --maxrregcount=128 -o lyra2/cuda_lyra2Z.o -c lyra2/cuda_lyra2Z.cu
 .
 lyra2/cuda_lyra2Z.cu(880): error: identifier "DMatrix" is undefined
 .
 ccminer-tpruvot (2.2.4-3) unstable; urgency=medium
 .
   * Support CUDA 9.1 in debian/rules for Debian Buster and Ubuntu Bionic.
   * Enable libssl 1.1 build, as 1.0 is conflicting with libcurl4-openssl-dev
     on Ubuntu Bionic.
   * Apply upstream pull request #56 to improve Lyra2rev2.
   * Custom patch to fix Lyra2Z build on CUDA arch < 50.
Author: Adam Cecile <acecile@le-vert.net>

---

Origin: other
Bug: TODO
Forwarded: no
Reviewed-By: Myself
Last-Update: 2018-03-27

Index: ccminer-mtp-1.1.5/lyra2/cuda_lyra2Z_sm5.cuh
===================================================================
--- ccminer-mtp-1.1.5.orig/lyra2/cuda_lyra2Z_sm5.cuh
+++ ccminer-mtp-1.1.5/lyra2/cuda_lyra2Z_sm5.cuh
@@ -24,7 +24,7 @@ void Gfunc(uint2 & a, uint2 &b, uint2 &c
 #endif
 }
 
-#if __CUDA_ARCH__ == 500 || __CUDA_ARCH__ == 350
+#if __CUDA_ARCH__ >= 350 && __CUDA_ARCH__ <= 500
 #include "cuda_lyra2_vectors.h"
 
 #define Nrow 8
