4.7 KiB
android_local_manifest
Local manifest for building LineageOS 23.2 (Android TV) for the Orange Pi 5 Ultra (Rockchip RK3588).
Prerequisites
- A Linux build host with LineageOS build dependencies installed
- ~250GB free disk space
repotool installed- An SD card (or other block device) at least 20GB, plus
sfdisk/kpartx/mkfs.vfat/mkfs.ext4(all standardutil-linux/e2fsprogstools) for creating the flashable image
Setup
# Initialize LineageOS 23.2 source tree
repo init -u https://github.com/LineageOS/android.git -b lineage-23.2
# Add this local manifest
curl -o .repo/local_manifests/manifest.xml -L https://git.bscubed.dev/lineage-rockchip/android_local_manifest/raw/branch/lineage-23.2/manifest.xml --create-dirs
# Sync the full source tree (including local manifest overrides)
repo sync -c -j$(nproc)
Updating the local manifest
curl -o .repo/local_manifests/manifest.xml -L https://git.bscubed.dev/lineage-rockchip/android_local_manifest/raw/branch/lineage-23.2/manifest.xml --create-dirs
repo sync --force-sync
Building
# Set up build environment
source build/envsetup.sh
# Select the Android TV target
breakfast tart
# Build
mka
Use plain mka (no target — this builds the default droid goal), not mka bacon. This device has no Android recovery (TARGET_NO_RECOVERY := true, U-Boot/extlinux boots it directly), which means INTERNAL_OTA_PACKAGE_TARGET is never assigned by the build system. bacon's OTA-zip packaging rule depends on that variable and has no other build dependencies, so it fails almost instantly and aborts the whole build before system.img/vendor.img are even produced. Plain mka builds everything this device actually needs — boot.img, system.img, vendor.img, ramdisk.img — without ever touching that broken rule.
Creating a flashable image
Once the build finishes, device/rockchip/tart/mkimg.sh assembles a bootable GPT image (U-Boot + FAT32 boot partition with extlinux.conf/kernel/DTB/ramdisk + system/vendor/metadata/userdata partitions):
# Run in the same shell you built in (needs TARGET_PRODUCT / ANDROID_PRODUCT_OUT
# from `breakfast`), from the root of the source tree. Do NOT prefix with sudo —
# root wouldn't see those env vars; the script escalates privileges internally
# per-command only where needed:
device/rockchip/tart/mkimg.sh
This produces out/target/product/tart/lineage-<LINEAGE_VERSION>.img. Write it to an SD card:
sudo dd if=out/target/product/tart/lineage-*.img of=/dev/sdX bs=4M status=progress
(Replace /dev/sdX with your SD card's device node — not a partition like /dev/sdX1.)
Fast re-flashing during development
device/rockchip/tart/wrimg.sh writes individual partition images directly to an already-flashed physical device, without rebuilding the whole GPT image — useful when iterating on system/vendor without wanting to recreate the boot partition each time:
device/rockchip/tart/wrimg.sh # writes boot + system + vendor
device/rockchip/tart/wrimg.sh system # writes system only
device/rockchip/tart/wrimg.sh vendor # writes vendor only
device/rockchip/tart/wrimg.sh boot # writes boot only
device/rockchip/tart/wrimg.sh wipe # reformats userdata
device/rockchip/tart/wrimg.sh wipe-metadata # reformats metadata
It auto-detects the target device by matching partition labels/sizes against mkimg.sh's layout (boot/system/vendor/metadata/userdata), so the device must already have been flashed with an image from mkimg.sh at least once.
Repositories
This local manifest pulls in the following repositories from git.bscubed.dev/lineage-rockchip/:
| Repository | Path | Description |
|---|---|---|
android_device_rockchip_tart |
device/rockchip/tart |
Device tree |
android_kernel_rockchip_tart |
device/rockchip/tart-kernel |
Kernel (prebuilt) |
android_vendor_rockchip_tart |
vendor/rockchip/tart |
Vendor blobs (firmware) |
android_external_drm_hwcomposer |
external/drm_hwcomposer |
DRM hwcomposer |
android_external_ffmpeg |
external/ffmpeg |
FFmpeg media library |
android_external_ffmpeg_codec2 |
external/ffmpeg_codec2 |
FFmpeg C2 codec HAL |
android_external_alsa-lib |
external/alsa-lib |
ALSA library |
android_external_alsa-utils |
external/alsa-utils |
ALSA utilities |
android_external_libudev-zero |
external/libudev-zero |
libudev compatibility |
Branch
All repositories use the lineage-23.2 branch.
License
Device tree and build scripts: Apache-2.0 External repositories retain their original licenses.