#Compiling kernel modules targeting different kernel version

5 messages · Page 1 of 1 (latest)

vast escarp
#

I have a kernel module which I'd like to compile to a different machine than the one I'm using.
I am running on a 5.19.0-50-generic kernel version, and the target is on 3.7.1.

After some googling, I found out that downloading kernel headers should be enough., but I'm not sure where should I download them from.

I would appreciate any help,
thanks in advanced,
J

visual cargo
# vast escarp I have a kernel module which I'd like to compile to a different machine than the...

Official Kernel Website

Using Package Manager: If you're using a Debian-based system, you can use the apt package manager to install kernel headers. However, older versions might not be available in the default repositories. For the 3.7.1 version, you might need to search for a specific PPA or repository that hosts it

Building from Source: If you download the full kernel source from the official website, you can also generate the headers by building the kernel. This might be overkill if you only need the headers, but it's an option if you can't find a pre-packaged version

#

Check my bio to more informations

vast escarp
# visual cargo Official Kernel Website Using Package Manager: If you're using a Debian-based s...

Hi, thank you so much for taking the time to answer 🙏 . Yeah I figured that 😅, it's just that the only archive I found which had something close to that was https://kernel.ubuntu.com/~kernel-ppa/mainline/, and after using wayback machine on it, I only found one out of two header files (this is the one from the wayback machine: https://web.archive.org/web/20170927195456/http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.7.1-raring/linux-headers-3.7.1-030701-generic_3.7.1-030701.201212171620_i386.deb, this is the one missing https://kernel.ubuntu.com/~kernel-ppa/mainline/v3.7.1-raring/linux-headers-3.7.1-030701_3.7.1-030701.201212171620_all.deb). I also tried building the kernel, but it seems that I need to downgrade my gcc, and it does not look fun at all. If you know of any other archiving source I'd love to know! thanks again anyway.

neat larkBOT
#

@vast escarp Has your question been resolved? If so, run !solved :)