Files
mikrotik-olsr/docs/building.md
T
feedc0de 63e038e6e8
Check source / check (push) Successful in 16s
Build RouterOS package release / release (push) Successful in 3m8s
Publish and promote RouterOS project site / site (push) Failing after 6s
Add update feed and ARM64 release support
2026-11-21 20:51:10 +01:00

5.1 KiB

Detailed builds

Use the prerequisites and key generation commands in the README first.

Complete core bundle

python tools/build-release.py --version 7.25.1 --arch arm \
  --wifi wifi-qcom-ac --keys .keys/local.json --output dist

This downloads official inputs, verifies NPK signatures, patches both installers and the RouterOS system package, re-signs Wi-Fi, and emits:

  • routeros-7.25.1-arm.npk
  • wifi-qcom-ac-7.25.1-arm.npk
  • netinstall-7.25.1-linux.tar.gz
  • netinstall-7.25.1-windows.zip
  • public-key.json, manifest.json, and SHA256SUMS

Use an empty output directory each time. Input archives are cached under build/. Input hashes and the source commit are recorded in the manifest. These identify what was used; hashes recorded after an HTTPS download are not an independent MikroTik signature on Netinstall. NPK inputs additionally undergo Ed25519 checking.

The tools retain package version and architecture metadata. Do not mix different RouterOS versions, architectures, or publishers' keys. ARMv7 and ARM64/AArch64 NPK generation are now available in the build scripts; only ARMv7 has completed hardware acceptance. ARM64 output must be treated as experimental until it has been installed and tested on an ARM64 router. The release builder has also been locally verified against RouterOS 7.23.8 ARM and 7.24.6 ARM/ARM64 inputs.

Build option and OLSR payloads

tools/build-runtime.sh arm
python tools/build-release.py --version 7.25.1 --arch arm \
  --wifi wifi-qcom-ac --keys .keys/local.json --output dist-with-runtime \
  --option-root build/runtime-arm/option-root --olsr-root build/runtime-arm/olsr-root

The runtime script downloads checksum-pinned ARM or ARM64 musl cross tools and BusyBox source, and checks out a pinned OLSRv1 source revision. It builds a minimal static BusyBox and the OLSR daemon. It never downloads option.npk from another firmware publisher. For AArch64 packages, stage the AArch64 payloads and use the matching arm64 system/add-on templates:

tools/build-runtime.sh arm64
python tools/build-release.py --version 7.25.1 --arch arm64 \
  --keys .keys/local.json --output dist-arm64 \
  --option-root build/runtime-arm64/option-root --olsr-root build/runtime-arm64/olsr-root

Select --wifi wifi-qcom only for compatible ARM64 hardware. wifi-qcom-ac is the ARMv7 package. Omit Wi-Fi when the device does not need it, especially on small-storage hardware. You can also provide your own audited payload directories instead of running the runtime cross-build.

The resulting option package contains BusyBox utilities, not another publisher's license generator or shell-unlock implementation. The resulting olsr package contains the daemon and experimental service payload. Its current startup uses a persistent RouterOS scheduler object and its route adapter uses BGP; it does not create native /olsr command handlers. See routeros-internals.md for package anatomy, UI limits, and the distinction between this adapter and the intended native subsystem.

The cross compiler itself is a prebuilt, checksum-pinned toolchain. This is not a claim that every build tool has been bootstrapped from independently audited source. Build timestamps/compression metadata can differ; byte-for-byte reproducibility has not been established.

Install

Back up the router's configuration and keep the official installer and official NPKs available for recovery. Use the device's documented Etherboot procedure. For a directly connected lab setup, for example:

sudo ip address add 192.168.88.2/24 dev YOUR_ETHERNET_INTERFACE
sudo ./netinstall-cli -e -a 192.168.88.3 routeros-7.25.1-arm.npk

Here ./netinstall-cli must be the patched binary extracted from your release, and -e deliberately erases the existing configuration. It avoids the default WAN-port firewall that can block management access when using -r. Connect with MAC Winbox after an empty-config install and configure an appropriate management address. If you choose -r, understand the device's default LAN/WAN port roles. The address passed with -a belongs to the temporary installer, not necessarily the installed RouterOS system.

Select only packages that fit the device. Install additional matching NPKs through RouterOS's normal package process once the custom-key system is running. Do not force a full runtime/Wi-Fi bundle onto a small-flash device just because the files were built successfully.

Signing model

The keyset contains independent Ed25519 and Curve25519/KCDSA private/public pairs. The NPK writer emits both signature formats. The modern RouterOS v7 Ed25519 verification key is replaced in installers and the installed system. This tool is not a RouterOS v6/legacy-signature migration tool.

--source-key allows an explicit different source publisher for experiments. The default accepts the known official v7 signing key. Do not change it merely to make an unexplained signature failure disappear.

A Netinstall executable can be patched using only the public export. Signing or creating NPKs requires the private keyset. Never put the private keyset in an NPK, archive, Git commit, CI artifact, release asset, or website.