Failing to build nvidia kmod

I’ve just enabled copr repository dan-james/kernel-cachyos and installed kernel-cachyos-6.19.0.01. The graphics failed to work when I boot into this kernel. While manually running sudo akmods it fails to build the kmods:

Checking kmods exist for 6.19.0.01-cachyos.20260128.fc43.x86_64 [ OK ]
Building and installing nvidia-kmod [FAILED]
Building rpms failed; see /var/cache/akmods/nvidia/580.119.02-1-for-6.19.0.01-cachyos.20260128.fc43.x86_64.failed.log for details

In the log file I get many errors like this

akmodsbuild: ././common/inc/nv-mm.h:221:19: error: assignment of read-only member ‘vm_flags’

which I have no idea.

Does anyone know how to deal with that?

The rpmfusion nvidia drivers as tested to build against Fedora kernels.
You are not running a Fedora kernel.

2 Likes

As @barryascott noted, CachyOS is not Fedora. In fact, it’s based upon Arch Linux, which isn’t Fedora either.

Perhaps the forums for those products will yield a better result:

Good luck!

okay, thank you for that, I might have to figure it out myself

the outdated driver 580.119.02 does not support kernel 6.19, which is stilll in RC stage. Mainline kernel is still 6.18.

you may want to try upgrading to the 590 driver available for rawhide/f44.

1 Like

Oh, thank you for that. That’s what I’ve been suspecting later on. Yet I’ve not sure where exactly should I refer to to get the compatibility of any given version of nvidia driver. I’ve checked here GeForce Driver Results | NVIDIA but couldn’t find information on that. How do you think about that?

The minimum requirements can be found in the driver documentation. Nvidia officially only supports kernels released at the time of driver release.
i.e the new released driver 580.126.18 is the only driver with support for kernel 6.19 OOTB.