lol

python312Packages.triton-bin: fix build

authored by

Jean-Baptiste Giraudeau and committed by
Jörg Thalheim
f34762ee 8a092985

+4 -25
+4 -25
pkgs/development/python-modules/triton/bin.nix
··· 49 49 dontStrip = true; 50 50 51 51 # If this breaks, consider replacing with "${cuda_nvcc}/bin/ptxas" 52 - postFixup = 53 - '' 54 - chmod +x "$out/${python.sitePackages}/triton/third_party/cuda/bin/ptxas" 55 - '' 56 - + ( 57 - let 58 - # Bash was getting weird without linting, 59 - # but basically upstream contains [cc, ..., "-lcuda", ...] 60 - # and we replace it with [..., "-lcuda", "-L/run/opengl-driver/lib", "-L$stubs", ...] 61 - old = [ "-lcuda" ]; 62 - new = [ 63 - "-lcuda" 64 - "-L${addDriverRunpath.driverLink}" 65 - "-L${cudaPackages.cuda_cudart}/lib/stubs/" 66 - ]; 67 - 68 - quote = x: ''"${x}"''; 69 - oldStr = lib.concatMapStringsSep ", " quote old; 70 - newStr = lib.concatMapStringsSep ", " quote new; 71 - in 72 - '' 73 - substituteInPlace $out/${python.sitePackages}/triton/common/build.py \ 74 - --replace '${oldStr}' '${newStr}' 75 - '' 76 - ); 52 + postFixup = '' 53 + mkdir -p $out/${python.sitePackages}/triton/third_party/cuda/bin/ 54 + ln -s ${cudaPackages.cuda_nvcc}/bin/ptxas $out/${python.sitePackages}/triton/third_party/cuda/bin/ 55 + ''; 77 56 78 57 meta = with lib; { 79 58 description = "Language and compiler for custom Deep Learning operations";