I want to make changes to the kernel files /linux/net/ipv4/ip_output.c in my case. I want to add a script to be run that changes the payload of the data whenever a packet passes through the IP_LOCAL_OUTPUT hook. Now when I add that script, how do I recompile the kernel that make the changes operable.
Asked
Active
Viewed 142 times
1
1 Answers
0
Ubuntu and Debian have thier own way to rebuild kernel. Methods from other distros DO NOT apply. Here is the right procedure, follow the apt-src
way.

Barafu Albino
- 6,541
-
P.S. If you remove modules from menuconfig while using this way, it will not compile. I believe there is a config line for this case. – Barafu Albino Mar 30 '14 at 10:04
-
When shall i make changes to the files i want as i mentioned in linux/net/ipv4/ip_output.c file? Shall I change it after the first step of getting the source code using apt-get source linux-image-$(uname -r). and then go ahead with next steps? Sorry if this is a silly question to ask – user263533 Mar 30 '14 at 10:49
-
Makefile:497: /home/ip-center/linux-3.9/arch//Makefile: No such file or directory make: *** No rule to make target `/home/ip-center/linux-3.9/arch//Makefile'. Stop.
– user263533 Mar 30 '14 at 09:42