# Compile Ubuntu Desktop for Intel CPU's Linux Kernel From Source ###### tags: `linux2021 jserv 1-on-1` # Steps * Get the kernel source code that is used for building the currently running system and [build it](https://phoenixnap.com/kb/build-linux-kernel) * [`software-properties-gtk`](https://askubuntu.com/questions/496549/error-you-must-put-some-source-uris-in-your-sources-list) -> tick the `source code` box * You can check `/etc/apt/sources.list` * setup build dependencies * `sudo apt-get build-dep linux linux-image-$(uname -r)` * `sudo apt-get install git fakeroot build-essential ncurses-dev xz-utils libssl-dev bc flex libelf-dev bison` * get source code `sudo apt-get source linux-image-unsigned-$(uname -r)` * Or use `git clone git://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/focal` * as recommended by running the `apt-get source` command * build the kernel ``` make menuconfig make -j 8 sudo make modules_install sudo make install ``` * issue * `make[1]: *** No rule to make target 'debian/canonical-certs.pem', needed by 'certs/x509_certificate_list'. Stop.` * `scripts/config --disable SYSTEM_TRUSTED_KEYS` * kernel will be made as default for the next boot, automatically * uninstall the kernel * TBD # cacULE * **For cacULE**: simply get the patched kernel tree `https://github.com/hamadmarri/linux`, and compile normally