This page describes the procedure for building a custom FreeBSD kernel. Before performing this procedure, you should review the FreeBSD Handbook article Building and Installing a Custom Kernel.
If your sources have been updated since your last ‘make world’ (or since installation if you haven’t done a ‘make world’ yet), you should follow the steps listed in the Make World cheat sheet instead of this procedure.
- Start with a copy of the GENERIC kernel’s configuration file:
- Edit the configuration file as required for the installed hardware. Remember, /usr/src/sys/i386/conf/NOTES is your friend!
- Compile and install the new kernel:
- Reboot the machine and cross your fingers.
# cd /usr/src/sys/i386/conf
# cp GENERIC YOURKERNEL
# cd /usr/src
# make buildkernel KERNCONF=YOURKERNEL
# make installkernel KERNCONF=YOURKERNEL
# shutdown -r now