Draft: Add dummy device family to help port Mobian to new devices
Porting a new device to Mobian often involves adding custom config files and packages, requiring heavy modifications to the existing recipes.
By providing a dummy device family and a few changes to the build script, we can provide an infrastructure for such custom changes:
- .deb packages put in
devices/wip/packages
will be automatically installed (along with their dependencies) - device-dependent firmware files should be copied to
devices/wip/firmware
so they're automatically deployed to/lib/firmware
on the device's rootfs - the directory structure under
devices/wip/rootfs
will be copied to the image's/
(overwriting existing files if needed)
Building such a custom image can be done by executing the following command:
./build.sh -i -t wip-<arch>:<vendor>+<device>
Where:
- is the processor architecture (one of
amd64
,armhf
orarm64
) - is the processor manufacturer as it appears in the kernel's
arch/<arch>/boot/dts/
folder (qcom
for Qualcomm,allwinner
for Allwinner,freescale
for NXP...) - is the DTS filename corresponding to the device (ex:
sdm845-oneplus-enchilada
for the OnePlus6)
Note: for armhf devices, DTB files are all put under arch/arm/boot/dts
and there is no per-vendor subfolder. In that case, the target name would be
wip-<arch>:+<device>
(ex: wip-armhf:+qcom-msm8974-lge-nexus5-hammerhead
for the Google/LG Nexus 5)
It is recommended to append the following additional flags:
-
-r
for Android devices -
-m 4G
if you experience build failures -
-F ext4
if your kernel has F2FS support compiled as a module (please note ext4 support must be built-in)
This should hopefully help porting Mobian to more devices.
Edited by Arnaud Ferraris