From f5378ccb5dc58890315eceda053605e6eebd54fe Mon Sep 17 00:00:00 2001 From: Daniel Fullmer Date: Wed, 27 Dec 2023 15:38:22 -0800 Subject: [PATCH] cudaPackages: apply runpath setup hooks to non-executable ELF files --- .../cuda-modules/setup-hooks/auto-add-cuda-compat-runpath.sh | 2 +- .../cuda-modules/setup-hooks/auto-add-opengl-runpath-hook.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/cuda-modules/setup-hooks/auto-add-cuda-compat-runpath.sh b/pkgs/development/cuda-modules/setup-hooks/auto-add-cuda-compat-runpath.sh index 537daad2f00e..ae25cebaca6f 100644 --- a/pkgs/development/cuda-modules/setup-hooks/auto-add-cuda-compat-runpath.sh +++ b/pkgs/development/cuda-modules/setup-hooks/auto-add-cuda-compat-runpath.sh @@ -10,7 +10,7 @@ elfHasDynamicSection() { autoAddCudaCompatRunpathPhase() ( local outputPaths mapfile -t outputPaths < <(for o in $(getAllOutputNames); do echo "${!o}"; done) - find "${outputPaths[@]}" -type f -executable -print0 | while IFS= read -rd "" f; do + find "${outputPaths[@]}" -type f -print0 | while IFS= read -rd "" f; do if isELF "$f"; then # patchelf returns an error on statically linked ELF files if elfHasDynamicSection "$f" ; then diff --git a/pkgs/development/cuda-modules/setup-hooks/auto-add-opengl-runpath-hook.sh b/pkgs/development/cuda-modules/setup-hooks/auto-add-opengl-runpath-hook.sh index f50a5f6c25c6..a6eeef7c7699 100644 --- a/pkgs/development/cuda-modules/setup-hooks/auto-add-opengl-runpath-hook.sh +++ b/pkgs/development/cuda-modules/setup-hooks/auto-add-opengl-runpath-hook.sh @@ -9,7 +9,7 @@ elfHasDynamicSection() { autoAddOpenGLRunpathPhase() ( local outputPaths mapfile -t outputPaths < <(for o in $(getAllOutputNames); do echo "${!o}"; done) - find "${outputPaths[@]}" -type f -executable -print0 | while IFS= read -rd "" f; do + find "${outputPaths[@]}" -type f -print0 | while IFS= read -rd "" f; do if isELF "$f"; then # patchelf returns an error on statically linked ELF files if elfHasDynamicSection "$f" ; then