rsdk-build
Build RadxaOS system image.
Command usage
$ rsdk build [options] <product> [suite] [edition]
Options
--no-cache
Do not use cached build artifacts. This will result in rootfs rebuild.
--no-efi
Do not create EFI partition in the generated image.
-d | --debug
Enable debug output. This will also build rootfs into a folder for easier
examination.
--dry-run
Generate all build metadatas into a temporary folder and exit. The temporary
folder path will be printed to standard output.
-T | --test-repo
Build using Radxa APT test archives.
-m | --mirror <mirror_url>
Specify custom Debian / Ubuntu archive mirror URL.
-M <mirror_url>
Specify custom non-Debian non-Ubuntu archive mirror URL. This mirror should
serve both Radxa archives as well as any other 3rd party archives.
The following archives will use this mirror:
radxa
vscodium
-i | --image-name <image_name>
Set the system image name. (Default: output.img)
-h | --help
Show this message.
-k | --override-kernel
Override the default kernel profile. Ex: latest, rockchip, rk2312, etc.
-f | --override-firmware
Override the default firmware profile. Ex: latest, rknext, etc.
-p | --override-product
Override the default product profile. Ex: rock-4se, radxa-zero, etc
-P | --no-pkgs-json
Skip downloading and embedding Radxa pkgs.json metadata into the image.
--no-vendor-packages
Do not install the vendor package specified in product profile.
--debs <debs_dir>
Include <debs_dir> as the local package archive.
The packages in this archive will be preferred over all other archives.
Packages will be kept even after the build is completed, effectively
disabling any future upgrades on the included packages.
WARNING: the entire content of <debs_dir> will be included!
--sdboot
[EXPERIMENTAL] Enable systemd-boot.
This feature is off by default, as U-Boot will try EFI boot first before
Standard boot.
Only supported in some distros.
-s | --sector-size <sector_size>
Override image's sector size. Ex: 512 (default), 4096, etc.
This is used when the local storage has a different sector size compared
to the target storage.
By default, rsdk assumes running on a 512-byte sector storage, building
512B system image. This option can be used to create 4096B image that is
needed for UFS boot.
Building 512B image on non-512B storage is currently not supported.
Build RadxaOS image
When no suite or edition options is supplied, rsdk-build will use the product-specific default values, which are defined in src/share/rsdk/configs/products.json as the first element of the respective array.
Using ROCK 3C as an example, if you want to build a CLI image for RadxaOS Bullseye, you can run the following command:
rsdk build rock-3c bullseye cli
Mirror options
rsdk build supports changing both the Radxa APT repository (radxa-deb) and the Debian/Ubuntu upstream mirror:
-
-M <radxa-mirror>: change Radxa APT mirror (radxa-deb). For example:rsdk build -M https://mirrors.ustc.edu.cn/radxa-deb rock-3cIf you pass a third‑party radxa-deb mirror here,
rsdkwill disable Radxa pkgs.json usage by default, because those mirrors usually do not providepkgs.json. -
-m | --mirror <distro-mirror>: change Debian/Ubuntu mirror. For example:rsdk build -m https://mirrors.ustc.edu.cn rock-3c
You can also use them together to change both Radxa and Debian/Ubuntu mirrors:
rsdk build \
-M https://mirrors.ustc.edu.cn/radxa-deb \
-m https://mirrors.ustc.edu.cn \
rock-3c
Radxa pkgs.json option
By default, when using the official Radxa repository (https://radxa-repo.github.io/radxa-deb and its variants), rsdk downloads and embeds Radxa pkgs.json metadata into the image.
For third‑party radxa-deb mirrors that do not provide pkgs.json, you may want to disable this behavior.
You can explicitly skip downloading and embedding pkgs.json by using:
rsdk build -P rock-3c
or:
rsdk build --no-pkgs-json rock-3c
This option is useful when you know the current mirror does not provide pkgs.json.
RadxaOS output path
You can find the generated RadxaOS image as out/${product}_${suite}_${edition}/output.img.