Note: Last years I funded my semi-lab with 15+ various TVboxes by my private money and decided to stop investing my private money - effectively just (and seems only) - to increase sells of tv box vendors.
If you want me to work on various issues or add new hardware support - pls consider donation to help me get required hardware to work on. Please note that this will also increase my satisfaction from - currently free of charge - work on minimyth2/miniarch.
MiniArch is ArchLinux ARM set of SD card images offering plug&run ArchLinux on ARM SBC/TVbox. It is very minimal ArchLinux distribution with bootloader/Linux kernel maximally supporting given TVBox/SBC then offering https://wiki.archlinux.org
Currently supported (and tested) SBC/TVboxes
MiniArch artefact is part of following GAR based build ecosystem:
-Installing ArchLinux ARM on ARM SBC is currently multistep process (example)
MiniArch goal is to simplify above whole process to:
- Download of MiniArch SD card image prepared for your SBC/TVbox
- burn image on SD card
- insert SD Card into SBC/TVbox
- power-on
- do update (see Quick Start below)
- enjoy full ArchLinux capabilities
-Adding to ArchLinux ARM ecosystem MiniMyth2 developed support for SBC/TVboxes including hardware video decode capabilities (with following results)
Requirements:
- Make sure your box is connected to Eth, has IP and Internet access
Note: pls do all below steeps in exact order like below. Otherwise install will fail!
- Download SD card Image
- burn image on SD card
- insert SD Card into SBC/TVbox
- power-on
- do update
- local login as root:root (ssh user:pass are alarm:alarm)
- type
start
- select (1) to init keyring and key
- type
start
- select (2) to do full update
- reboot
- type
start
- select (4) to resize root partition to full possible size
- type
start
- select (5) to update MiniArch artefacts
- reboot
- enjoy (i.e. install EndeavourOS by typing
start
then (6) or setup ArchLinux OS acordingly to Archlinux Wiki
Note: pls do all below steeps in exact order like below. Otherwise install will fail!
- Download SD card Image
- burn image on SD card
- insert SD Card into SBC/TVbox
- power-on
- do update
- local login as root:root (ssh user:pass are alarm:alarm)
- type
start
- select (1) to init keyring and key
- type
start
- select (2) to do full update
- reboot
- type
start
- select (5) to update MiniArch artefacts
- reboot
- transfer system to eMMC
- type
start
- select (3)
- when script ends with success, remove SD Card and reboot
- type
- Continue install
- type
start
- select (4) to resize root partition to full possible size
- reboot
- type
- enjoy (i.e. install EndeavourOS by typing
start
then (6) or setup ArchLinux OS acordingly to Archlinux Wiki
NOTE: do not skip step (update MiniArch artefacts) as this step - beside updating MiniArch components - also fixes bugs/issues/show stoppers in Generic AArch64 ArchLinux ARM code
NOTE2: sometimes there are issues with Archlinux ARM mirrors avaliability. In such case do full update (option 2 in start) will be constantly failing. To overcome this You may change mirror to other one with hope other one will work better. In such case look on list of avaliable servers is here list of mirrors and do following:
On command prompt do:
(example for chnaging mirror to http://de3.mirror.archlinuxarm.org):
mv /etc/pacman.d/mirrorlist /etc/pacman.d/mirrorlist.bak
echo Server = 'http://de3.mirror.archlinuxarm.org/$arch/$repo' >> /etc/pacman.d/mirrorlist
Verify Your change by:
cat /etc/pacman.d/mirrorlist
Try again with update by start 1
Currently automated MiniArch build process is following:
- cross building current mainline Linux kernel and firmware with MiniMyth2 applied patches to offer support of SBC/TVboxes
- cross-building selected SBC/TVbox bootloader files
- cross-building ArchLinux kernel and firmware PKGs from p.1
- downloading ArchLinux ARM Generic AArch64 ArchLinux ARM rootfs
- unpacking rootfs from p.4 on x86 host
- cross-installing ArchLinux kernel and firmware PKGs generated in p.3 on unpacked rootfs from p.5 on x86 host
- cross-regenrating initramfs on rootfs from p.6
- packing above rootfs to Generic AArch64 Installation archive for upload to MiniArch github
- preparing SD card image with updated rootfs and bootloader prepared in p.2 and p.7
- xz packing SD card image for upload to MiniArch github
In above context, we may say: MiniArch is minimally required changed ArchLinux ARM to boot and work on Your box and it offers maximum compatibility with ArchLinux ARM (except kernel modules).
MiniArch specific components:
- linux-aarch64
- linux-aarch64-headers
- linux-aarch64-api-headers
- linux-firmware
- miniarch-meta
are blocked in ArchLinux ARM pacman official repo updates and are separately offered in dedicated repo called MiniArch
Any MiniMyth2 kernel update will also produce updated above PKGs.
You can update MiniArch with kernel/firmware by:
- login as root:root
- type 'start'
- select (4) to do "update MiniArch artefacts"
Happy burning!
MiniArch is just another project (like MiniMyth2) living in build system MiniMyth2 uses. For some background - please look https://github.com/warpme/minimyth2/wiki/Build-Instructions
- setup build system by following minimyth2 build instructions from https://github.com/warpme/minimyth2/wiki/Build-Instructions till
cd ~/minimyth2/script/meta/minimyth/
- instead of
cd ~/minimyth2/script/meta/minimyth/
docd ~/minimyth2/script/meta/miniarch/
- run
./build-image-for-board.sh
- type number to select desired board then press Enter
- after some time Yuo should got sd card image for selected board in
build
dir - flash to sd card. it should work ok
MiniArch (the same like MiniMyth2) uses common build system based on GAR (https://www.linuxjournal.com/article/5819)
Most frequently actions are described here: https://github.com/warpme/minimyth2/wiki/Developing-MiniMyth2
MiniArch related components are in ~/minimyth2/script/miniarch
- go to
~/minimyth2/script/kernel/linux-x.y/work/main.d/linux-x.y.z
- do desired changes in kernel code
- go to
~/minimyth2/script/kernel/linux-x.y
- run
make rebuild reinstall
- go to
~/minimyth2/script/miniarch
- run
make update-kernel
- run
./build-image-for-board.sh
- type number to select desired board then press Enter
- after some time You should get sd card image for selected board in
build
dir
Note: running make clean in ~/minimyth2/script/kernel/linux-x.y
will delete all your changes. If you want to have them permanently, please do following:
Here is example for linux kernel:
- go to
~/minimyth2/script/kernel/linux-x.y
- run
make clean patch
- do desired changes in kernel code in
~/minimyth2/script/kernel/linux-x.y/work/main.d/linux-x.y.z
- run
make makepatch
in~/minimyth2/script/kernel/linux-x.y
- you will get
current-changes.patch
file in~/minimyth2/script/kernel/linux-x.y
copy this file to~/minimyth2/script/kernel/linux-x.y/files
dir with desired patch_file_name - add
PATCHFILES += patch_file_name
entry in~/minimyth2/script/kernel/linux-x.y/Makefile
at end of PATCHFILES +=... list - go to
~/minimyth2/script/kernel/linux-x.y
and runmake makesums-all
Now you can build kernel with your changes by make clean install
in ~/minimyth2/script/kernel/linux-x.y
and then build MiniArch image by following Example: rebuilding MiniArch image with updated kernel
Note: due nature how patch
utility works - please do make makepatch
on clean sources.
If you do this on sources with build artefacts - then current-changes.patch
file will contain also build artefacts.
To avoid this, you may do whole Include your code changes in MiniMyth2 build system procedure in some temp dir.
Example:
- copy
~/minimyth2/script/kernel/linux-x.y
to~/minimyth2/script/kernel/linux-x.y-temp
- go to
~/minimyth2/script/kernel/linux-x.y-temp
and do Include your code changes in MiniMyth2 build system procedure - copy
current-changes.patch
file from~/minimyth2/script/kernel/linux-x.y-temp
to~/minimyth2/script/kernel/linux-x.y/files
dir with desired patch_file_name - add
PATCHFILES += patch_file_name
entry in~/minimyth2/script/kernel/linux-x.y/Makefile
at end of PATCHFILES +=... list - go to
~/minimyth2/script/kernel/linux-x.y
and runmake makesums-all
Now you can build kernel with your changes by make clean install
in ~/minimyth2/script/kernel/linux-x.y
and then build MiniArch image by following Example: rebuilding MiniArch image with updated kernel
Happy building