1{ lib
2, stdenv
3, callPackage
4, rocm-opencl-runtime
5}:
6
7stdenv.mkDerivation rec {
8 pname = "rocm-opencl-icd";
9 version = rocm-opencl-runtime.version;
10
11 dontUnpack = true;
12
13 installPhase = ''
14 mkdir -p $out/etc/OpenCL/vendors
15 echo "${rocm-opencl-runtime}/lib/libamdocl64.so" > $out/etc/OpenCL/vendors/amdocl64.icd
16 '';
17
18 passthru.impureTests = { rocm-opencl = callPackage ./test.nix { }; };
19
20 meta = with lib; {
21 description = "OpenCL ICD definition for AMD GPUs using the ROCm stack";
22 license = licenses.mit;
23 maintainers = with maintainers; [ lovesegfault ] ++ teams.rocm.members;
24 platforms = platforms.linux;
25 };
26}