I need to build an older kernel, namely 5.16.9, on NixOS 22.11 in order to find a bug as mentioned in another thread here: Building kernel 5.16.9 from source fails, how to downgrade dwarves/pahole
However due to some problem with pahole
version 1.24 these kernels no longer build on NixOS 22.11. Downgrading to pahole
version 1.23 should avoid the issue as mentioned here: pahole v1.24: FAILED: load BTF from vmlinux: Invalid argument
Question How to downgrade pahole
in building the Linux kernel short of downgrading NixOS as a whole? Since pahole
is in the nativeBuildInputs
in this file here nixpkgs/manual-config.nix at fbf79d73ec78596a7e9f0449619412ef13cdcbf8 · NixOS/nixpkgs · GitHub I’d assume that is what I’d have to override.
Hence the more general question: How to override nativeBuildInputs
on buildLinux
?
(p.s. I decided to make another thread for this here in the development section as it is a rather specific question concerning the build process for the Linux kernel on NixOS. And it might concern others when formulating it this way.)