lol

Merge pull request #281376 from ConnorBaker/fix/cudaPackages-structuredAttrs-autoPatchelf

cudaPackages: __structuredAttrs works with autoPatchelf since #272752

authored by

Connor Baker and committed by
GitHub
15ee4760 75763758

+12 -10
+8 -5
pkgs/development/cuda-modules/cuda/overrides.nix
··· 23 23 final.pkgs.rdma-core 24 24 ]; 25 25 # Before 11.7 libcufile depends on itself for some reason. 26 - env.autoPatchelfIgnoreMissingDeps = 27 - prevAttrs.env.autoPatchelfIgnoreMissingDeps 28 - + strings.optionalString (cudaVersionOlder "11.7") " libcufile.so.0"; 26 + autoPatchelfIgnoreMissingDeps = 27 + prevAttrs.autoPatchelfIgnoreMissingDeps 28 + ++ lists.optionals (cudaVersionOlder "11.7") [ "libcufile.so.0" ]; 29 29 } 30 30 ); 31 31 ··· 69 69 70 70 cuda_compat = prev.cuda_compat.overrideAttrs ( 71 71 prevAttrs: { 72 - env.autoPatchelfIgnoreMissingDeps = 73 - prevAttrs.env.autoPatchelfIgnoreMissingDeps + " libnvrm_gpu.so libnvrm_mem.so libnvdla_runtime.so"; 72 + autoPatchelfIgnoreMissingDeps = prevAttrs.autoPatchelfIgnoreMissingDeps ++ [ 73 + "libnvrm_gpu.so" 74 + "libnvrm_mem.so" 75 + "libnvdla_runtime.so" 76 + ]; 74 77 # `cuda_compat` only works on aarch64-linux, and only when building for Jetson devices. 75 78 badPlatformsConditions = prevAttrs.badPlatformsConditions // { 76 79 "Trying to use cuda_compat on aarch64-linux targeting non-Jetson devices" =
+4 -5
pkgs/development/cuda-modules/generic-builders/manifest.nix
··· 276 276 ''; 277 277 278 278 # libcuda needs to be resolved during runtime 279 - # NOTE: Due to the use of __structuredAttrs, we can't use a list for autoPatchelfIgnoreMissingDeps, since it 280 - # will take only the first value. Instead, we produce a string with the values separated by spaces. 281 - # Using the `env` attribute ensures that the value is representable as one of the primitives allowed by 282 - # bash's environment variables. 283 - env.autoPatchelfIgnoreMissingDeps = "libcuda.so libcuda.so.*"; 279 + autoPatchelfIgnoreMissingDeps = [ 280 + "libcuda.so" 281 + "libcuda.so.*" 282 + ]; 284 283 285 284 # The out output leverages the same functionality which backs the `symlinkJoin` function in 286 285 # Nixpkgs: