Skip to content

Approach A vs Approach B (Local BYOF Workflow) ​

UniOHOS keeps all public repositories 100% free of proprietary vendor binaries while supporting both pure open-source system builds and full hardware bring-up on consumer devices.

1. Side-by-Side Comparison ​

DimensionApproach A: Pure Open-Source OpenHarmony BaseApproach B: Local BYOF Firmware Synthesis
System Rootfs SourceUpstream open-source OpenHarmony (Apache-2.0)Locally synthesized on the user's computer from user-owned partitions (BYOF, Bring Your Own Firmware) + UniOHOS open-source adaptation layers
Proprietary Blobs Hosted by UniOHOS0 bytes0 bytes (only open-source code, schemas, and device.yaml recipes are published)
Graphics StackOpen-source Mesa (PanVK / Turnip / RADV / ANV / llvmpipe)Dual-engine router: local GPU via hybris-bridge with automatic Mesa fallback
Non-GPU HardwareOpen-source kernel & native VDI driversIsolated Bionic Sidecar mounting local /vendor read-only, incrementally replaceable by open drivers
Primary Use CaseStage 0-2 bring-up, kernel/ABI testing, open driver & firmware developmentStage 3-4 full hardware enablement (OpenHarmony / HarmonyOS) on user-owned unlocked devices
Current v0.1.0 CLI Supportuniohos-builder open-base-info (spec CLI; automated build recipes & CI preview images planned)uniohos-builder validate-device + byof-plan --dry-run + fs-tools (end-to-end automated assembly planned iteratively via PRs)

2. Approach A: Inspecting the Pure Open-Source Base Spec ​

Use UniOHOS/builder to query the Apache-2.0 OpenHarmony base target specification for arm64 or x86_64:

bash
uniohos-builder open-base-info --arch arm64
uniohos-builder open-base-info --arch x86_64 --json

The arm64 specification targets uniohos-open-base-arm64.erofs (Apache-2.0, proprietary_blobs_bytes: 0), combining:

  • OpenHarmony Musl libc, init, samgr, hilog, hdf_devmgr, and hdc
  • UniOHOS/core early-bringup plus generic DRM/KMS composer_vdi and buffer_vdi
  • Open-source Mesa 3D (PanVK for Arm Mali/Immortalis, Turnip for Qualcomm Adreno, llvmpipe fallback)
  • Critical modem and calibration partition ro,norecovery guards

3. Approach B: Local BYOF Synthesis Workflow ​

Under Approach B, all device-specific proprietary files stay strictly on the device owner's local workstation outside any Git directory.

Step 1: Dump Local Read-Only Partitions Outside Git ​

From your own unlocked device, archive the partitions declared under byof_inputs.local_partitions in device.yaml (for example vendor_a, odm_a, vendor_boot_a, dtbo_a) into a private local workspace directory (UNIOHOS_WORK_DIR). Never commit or attach these files to Git, Issues, or Pull Requests.

Step 2: Validate the Device Recipe ​

bash
uniohos-builder validate-device devices/xiaomi/dijun/device.yaml --json

The validator enforces device.schema.json (v1.0), including byof_inputs.zero_remote_blobs == true and selinux.zero_neverallow == true.

Step 3: Generate the 5-Step Offline Synthesis Plan ​

bash
uniohos-builder byof-plan --device devices/xiaomi/dijun/device.yaml --dry-run --json

byof-plan emits a deterministic 5-step local execution plan with remote_blob_downloads: 0:

  1. verify_local_byof_inputs: Confirm required local read-only partitions are present and list untouched low-level bootchain partitions.
  2. verify_gki_kernel_and_dtbo: Validate <vendor>-<soc>-kernel branch/tag, dtbo_target, zero GKI ABI CRC drift, and custom out-of-tree .ko modules via UniOHOS/gki-sdk.
  3. compile_core_and_bsp: Build UniOHOS/core and <vendor>-<soc>-bsp (bsp_profile or device_overlay_repo), primary GPU engine plus fallback Mesa driver, and declared Sidecar services.
  4. pack_tiered_erofs_and_selinux: Pack local read-only EROFS images (64KB PTE_CONT Tier-0 alignment via fs-tools) and incremental SELinux .cil policy (neverallow == 0), enforcing ro,norecovery guards on critical partitions.
  5. emit_non_destructive_slot_plan: Produce the target slot deployment plan (e.g., slot _b, keeping slot _a untouched for rollback).

Compliance Boundary

UniOHOS and UniOHOS-Devices repositories and GitHub Releases never host extracted OEM firmware, commercial system images, or proprietary .so/.ko/.ta files. See Compliance & BYOF Policy and LEGAL.md.

Independent Open-Source Community (CC-BY-4.0). Not affiliated with Huawei, HiSilicon, OpenAtom Foundation, Xiaomi, Qualcomm, MediaTek, or Arm.