Set `glibc/lib` as first `rpath` for `nvidia-container-cli`. Also
install nvidia libraries to `/usr/local/glibc/lib` so any musl libraries
lives separately.
`nvidia-container-cli` explicitly sets an `RPATH` as `$ORIGIN/../$LIB` here:
https://gitlab.com/nvidia/container-toolkit/libnvidia-container/-/blob/v1.14.6/Makefile?ref_type=tags#L183,
this means `/usr/local/lib` would be searched first, since `zfs` and
nvidia ship their own `libtirpc`, `nvidia-container-cli` first tries to
use the `libtirpc` shippeed with `zfs` at `/usr/local/lib` instead of
the one at `/usr/local/glibc/lib`. Fix this by setting an additional
`RPATH` as `$ORIGIN/../glibc/$LIB`, so that libraries in
`/usr/local/glibc/lib` have higher preference.
```bash
❯ scanelf -r _out/rootfs/rootfs/usr/local/bin/nvidia-container-cli
TYPE RPATH FILE
ET_DYN $ORIGIN/../glibc/$LIB:$ORIGIN/../$LIB _out/rootfs/rootfs/usr/local/bin/nvidia-container-cli
```
Properly fixes: #380
Fixes from #401 and #410 were not complete.
Manually tested by spinning up a NVIDIA worker in AWS.
Signed-off-by: Noel Georgi <git@frezbo.dev>
Introduce a proper fix for #401, keep musl path's as is, and use
`/usr/local/glibc` as install path for all glibc related stuff so that
any new common libraries will not cause an issue in the future.
Signed-off-by: Noel Georgi <git@frezbo.dev>
Use a custom path for libtirpc shipped with zfs-tools so that it doesn't
conflict with libtirpc built for nvidia-container-toolkit (as it's
linked against glibc).
Fixes: #380
Signed-off-by: Noel Georgi <git@frezbo.dev>
Use wolfi base as toolchain for NVIDIA build.
This removes a lot of hacks and patches we maintain.
Fixes: #171
Fixes: https://github.com/siderolabs/pkgs/issues/720
Signed-off-by: Noel Georgi <git@frezbo.dev>
Publish the OSS Nvidia kernel modules built against a release version of
Talos and also the nvidia toolkit required for running GPU workloads on
Kubernetes.
Signed-off-by: Noel Georgi <git@frezbo.dev>