ARM Build Scripts

Table of Contents

These are the same build scripts that we use to generate the pre-generated official Kali Linux ARM images, found here:

There are additional scripts included in the repository, supporting more devices, that we do not release images for, as well as archived scripts for historical purposes.

For more information, please see:


  • These scripts are tested on Kali Linux arm64, x64 and x86 installations only (We recommend x64)
  • Make sure you run the ./common.d/ script before trying to build an image, as this installs all required dependencies
  • You will need at least 8GB of RAM or use a SWAP file

An example workflow to build a Raspberry Pi 4 Kali Linux image would look like:

$ cd ~/
$ git clone
$ cd ~/kali-arm/
$ sudo ./common.d/
$ sudo ./
  • Depending on your system hardware & network connectivity, will depend on how long it will take to build (4 core CPU, 8GB RAM, SSD inside a VM takes using a local repo about 100 minutes per script)
  • On x64 or arm64 systems, after the script finishes running, you will have an image files located in ~/kali-arm/images/ called kali-linux-2024.2-raspberry-pi-xfce-armhf.img.xz
  • On x86 systems, as they do not have enough RAM to compress the image, after the script finishes running, you will have an image file located in ~/kali-arm/images/ called kali-linux-2024.2-raspberry-pi-xfce-armhf.img
    • Should you want to try and shrink the file to make it easier to distribute, you will need to use your own preferred compression.


On any build script, add --help. Example:

$ ./ --help
 Usage commands:
# Architectures (arm64, armel, armhf)
./ --arch arm64 or ./ -a armhf

# Desktop manager (xfce, gnome, kde, i3, lxde, mate, e17 or none)
./ --desktop kde or ./ --desktop=kde

# Minimal image - no desktop manager
./ --minimal or ./ -m

# Slim image - no desktop manager or cli tools
./ --slim or ./ -s

# Enable debug & log file (./logs/<file>.log)
./ --debug or ./ -d

# Perform extra checks on the images build
./ --extra or ./ -x

# Help screen (this)
./ --help or ./ -h

Custom Values

Editing builder.txt, will allow for custom values, such as using a local LAN mirror:

$ echo 'mirror=""' > ./builder.txt

A full list of values you can set:

# Version Kali release
#version=${version:-$(cat .release)}

# Custom hostname variable

# Choose a locale

# Free space added to the rootfs in MiB

# /boot partition in MiB

# Select compression, xz or none

# Choose filesystem format to format ( ext3 or ext4 )

# Disable IPV6 ( yes or no)

# Make SWAP ( yes or no)

# DNS server

# To limit the number of CPU cores to use during compression
# Use 0 for unlimited CPU cores, -1 to subtract 1 cores from the total

# To limit the CPU usage during compression
# 0 or 100 No limit, 10 = percentage use, 50, 75, 90, etc.

# If you have your own preferred mirrors, set them here.

# If you use a custom mirror that your users won't have access to , you can replace_mirror to point them at the official mirrors instead.

# Use packages from the listed components of the archive.

# Suite to use, valid options are:
# kali-rolling, kali-dev, kali-dev-only, kali-last-snapshot

# If you build against something other than kali-rolling, you can set this so that the finished image will point to the kali-rolling suite

# Default file name
# On the Raspberry Pi script, this would result in
# "kali-linux-202X-WXX-raspberry-pi-arm64" for the default filename.
# For release builds from Kali Linux, the requirements are that it start with kali-linux
# and end with the architecture.
#image_name="kali-linux-$(date +%Y)-W$(date +%U)-${hw_model}-${variant}"

Updated on: 2024-Jun-05
Author: steev