gpu-burn: tidy up after CUDA changes
Signed-off-by: Connor Baker <ConnorBaker01@gmail.com>
This commit is contained in:
@@ -6,7 +6,6 @@
|
||||
lib,
|
||||
}:
|
||||
let
|
||||
inherit (lib.attrsets) getBin;
|
||||
inherit (lib.lists) last map optionals;
|
||||
inherit (lib.trivial) boolToString;
|
||||
inherit (config) cudaSupport;
|
||||
@@ -36,7 +35,11 @@ backendStdenv.mkDerivation {
|
||||
substituteInPlace gpu_burn-drv.cpp \
|
||||
--replace-fail \
|
||||
'#define COMPARE_KERNEL "compare.ptx"' \
|
||||
"#define COMPARE_KERNEL \"$out/share/compare.ptx\""
|
||||
'#define COMPARE_KERNEL "${placeholder "out"}/share/compare.ptx"'
|
||||
substituteInPlace Makefile \
|
||||
--replace-fail \
|
||||
'${''''${CUDAPATH}/bin/nvcc''}' \
|
||||
'${lib.getExe cuda_nvcc}'
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
@@ -52,7 +55,8 @@ backendStdenv.mkDerivation {
|
||||
];
|
||||
|
||||
makeFlags = [
|
||||
"CUDAPATH=${getBin cuda_nvcc}"
|
||||
# NOTE: CUDAPATH assumes cuda_cudart is a single output containing all of lib, dev, and stubs.
|
||||
"CUDAPATH=${cuda_cudart}"
|
||||
"COMPUTE=${last (map dropDots cudaCapabilities)}"
|
||||
"IS_JETSON=${boolToString isJetsonBuild}"
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user