Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/deelerdev/linux/llms.txt

Use this file to discover all available pages before exploring further.

Before you build the kernel, verify that your system meets the minimum software requirements listed here. Running an outdated toolchain is a common source of mysterious build failures — the kernel’s Makefile will outright refuse to proceed if GNU Make is too old. You can check all installed tool versions at once by running:
./scripts/ver_linux
Run this from the root of your kernel source tree after cloning.

Current kernel version

The source files in this documentation correspond to Linux 7.1-rc3 (codename: Baby Opossum Posse), as defined in the top-level Makefile:
VERSION = 7
PATCHLEVEL = 1
SUBLEVEL = 0
EXTRAVERSION = -rc3
NAME = Baby Opossum Posse

Minimum required versions

Upgrade to at least these versions before reporting a build issue. The command shown in the third column prints the installed version on your system.
ProgramMinimum versionCheck command
bash4.2bash --version
bc1.06.95bc --version
binutils2.30ld -v
bison2.0bison --version
flex2.5.35flex --version
GNU C (gcc)8.1gcc --version
GNU make4.0make --version
GNU tar1.28tar --version
kmod13kmod -V
openssl & libcrypto1.0.0openssl version
pahole1.22pahole --version
Perl5perl --version
Python3.9.xpython3 --version
util-linux2.10omount --version
Not every tool is required on every system. If you are not using a particular feature — for example, PC Card hardware or NFS — you do not need the corresponding utility.

Core build tools

GNU C (gcc)

GCC 8.1 or later is required. The exact version requirements may vary depending on your CPU architecture. Check your installed version with:
gcc --version

GNU make

The kernel’s build system requires GNU Make 4.0 or later. The Makefile enforces this at the start of every build and will exit with an error if the requirement is not met:
make --version

Binutils

Binutils 2.30 or later provides the linker (ld) and other binary utilities. Check with:
ld -v

Bash

Several kernel build scripts require Bash 4.2 or newer:
bash --version

flex and bison

Since Linux 4.16, the build system generates lexical analyzers and parsers during the build. This requires flex 2.5.35 or later and bison 2.0 or later:
flex --version
bison --version

pahole

Since Linux 5.2, if CONFIG_DEBUG_INFO_BTF is selected, the build generates BTF (BPF Type Format) from DWARF debug info. This requires pahole 1.22 or later, found in the dwarves or pahole package on most distributions:
pahole --version

OpenSSL

Module signing and external certificate handling require the OpenSSL program and its development headers. Required for kernels 3.7 and later when module signing is enabled, and for all kernels 4.3 and later:
openssl version

pkg-config

Since Linux 4.18, the build system uses pkg-config to detect installed kconfig tools and determine flags for make {g,x}config. Install it from your distribution’s package manager.

Optional tools

You can build the kernel with Clang and LLVM as an alternative to GCC. Only the latest formal release from releases.llvm.org is supported; older releases are not guaranteed to work and workarounds for them may be removed from the kernel at any time.
clang --version
See the kernel documentation on Building Linux with Clang/LLVM for further details.
Rust support is optional and requires a recent stable Rust compiler. Check your installed version:
rustc --version
To verify that the full Rust toolchain is detected correctly by the build system, run:
make rustavailable
See Documentation/rust/quick-start.rst in the kernel source for complete Rust setup instructions.
bindgen generates Rust bindings to the C side of the kernel. It depends on libclang and is required only when building with Rust support enabled.
bindgen --version
GNU AWK is required if you enable CONFIG_BUILTIN_MODULE_RANGES, which generates address range data for built-in modules.
gawk --version
Required to generate tag files via make gtags. This version requirement exists because the build uses the gtags -C (--directory) flag introduced in 6.6.5.
gtags --version
Used when building a Flat Image Tree (FIT), which is commonly required on ARM platforms. Available via the u-boot-tools package.
mkimage --version
Required only if you want to build the kernel’s HTML, PDF, or other formatted documentation from the Documentation/ directory.
sphinx-build --version

Perl modules

You need Perl 5 and the following modules to build the kernel:
  • Getopt::Long
  • Getopt::Std
  • File::Basename
  • File::Find
These are included in most distributions’ base Perl packages.

Python

Python 3.9 or later is required by several configuration options, including arm/arm64 default configs, CONFIG_LTO_CLANG, some DRM optional configs, the kernel-doc tool, and the Sphinx documentation build.
python3 --version

Next steps

Build the kernel

Follow the step-by-step guide to clone, configure, and compile your kernel.

Submitting patches

Learn how to contribute your changes back to the kernel.

Build docs developers (and LLMs) love