New comment by namgo on void-packages repository https://github.com/void-linux/void-packages/issues/20077#issuecomment-1839277359 Comment: If anyone's still struggling with this (as I am) the cuda installer when extracted provides directories that can be merged into an "outdir" `NVCC=/opt/cuda-extract/outdir/bin/nvcc LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/cuda-extract/outdir/lib64/ INCLUDES="-I /opt/cuda-extract/outdir/include/ " PATH=$PATH:/opt/cuda-extract/outdir/bin/ NVVMIR_LIBRARY_DIR=/opt/cuda-extract/outdir/nvvm/libdevice/ CUDA_PATH=/opt/cuda-extract/outdir/targets/x86_64-linux/ (command)` at least points nvcc to the right place. This is isn't directly relevant to packaging as I don't think we can legally redistribute extracted cuda binaries. Edit: maybe we can?? https://archlinux.org/packages/extra/x86_64/cuda/ edit: I managed to get a python package to compile its cuda-required code successfully using the env vars above!