Skip to content

Commit ae9429f

Browse files
committed
Install the NVRTC header the cuDNN frontend includes in the CUDA prebuilt leg
1 parent 1957123 commit ae9429f

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

‎.github/workflows/unsloth-sd-prebuilt.yml‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,8 @@ jobs:
425425
# prefix (it ships as libcublas / libcublas-dev), so it has to go in the
426426
# other list or apt cannot find it. cudart-dev is what carries the headers;
427427
# cudart alone is the runtime and does not compile anything.
428-
sub-packages: '["nvcc", "cudart", "cudart-dev", "thrust"]'
428+
# nvrtc-dev: cudnn-frontend's headers include nvrtc.h (it dlopens libnvrtc itself, so nothing links it).
429+
sub-packages: '["nvcc", "cudart", "cudart-dev", "thrust", "nvrtc-dev"]'
429430
non-cuda-sub-packages: '["libcublas", "libcublas-dev"]'
430431

431432
# This leg rebuilt every object on every run: 3903 s of the 4121 s job on
@@ -527,11 +528,11 @@ jobs:
527528
patchelf --set-rpath '$ORIGIN' "$BIN/$exe"
528529
done
529530
ldd "$BIN/sd-cli" | sed -n '1,40p'
530-
# cuDNN is opened at run time only; a link-time dependency would stop the binaries
531+
# cuDNN and NVRTC are opened at run time only; a link-time dependency would stop the binaries
531532
# loading on every host without it.
532533
for exe in sd-cli sd-server; do
533-
if readelf -d "$BIN/$exe" | grep -q 'NEEDED.*cudnn'; then
534-
echo "ERROR: $exe links libcudnn; it must stay a run-time dlopen" >&2
534+
if readelf -d "$BIN/$exe" | grep -qE 'NEEDED.*(cudnn|nvrtc)'; then
535+
echo "ERROR: $exe links libcudnn or libnvrtc; they must stay run-time dlopens" >&2
535536
exit 1
536537
fi
537538
done

0 commit comments

Comments
 (0)