/mac-linux-kdk

Build ARM Linux Kernels natively on macOS hosts

Primary LanguageShellGNU Lesser General Public License v3.0LGPL-3.0

macOS Linux Kernel Development Kit

Build the (ARM/ARM64/i386) Linux Kernel on any macOS host

Details

The macOS Linux Kernel Development Kit includes some bits from glibc to successfully build host tools, which allows a full kernel compile on macOS with little effort.

NOTE: This is still early, and while at the time of this writing, mainline for arm64 and i386 (not amd64) successfully builds on Apple Silicon and Intel, this can change as the kernel continues development. Updates are welcome if things break.

Usage

  1. Install Homebrew for package management.

  2. Install mac-linux-kdk: brew tap markbhasawut/markbhasawut && brew -v install markbhasawut/markbhasawut/mac-linux-kdk

  3. Clone the Linux kernel source to a case-sensitive filesystem. (Use Disk Utility to add a case-sensitive volume)

  4. Use lkmake instead of make to build the Linux kernel.