User:Brendlefly62/Rockchip RK3399 Asus Tinker Board 2 S/Assemble a Gentoo System
From Gentoo Wiki
Jump to:navigation
Jump to:search
"Re-use" your Armbian-built system to deploy Gentoo
Move the contents of the Armbian root filesystem, install gentoo stage 3, and restore boot directory. Start by mounting the boot media (SD Card) on another workstation that has internet connectivity. Note: if possible, use another arm64 system so subsequent chroot steps will be possible.
root #
mount /dev/sdx1 /mnt/gentoo
root #
cd /mnt/gentoo
root #
mkdir armbian_rootfs
root #
mv -v * /armbian_rootfs/ # ignore error about moving this directory into itself
root #
cat stage3-*.DIGESTS
root #
sha512sum stage3-arm64-openrc-20240505T234912Z.tar.xz
(compare to saved hash)
- (continue, basically as outlined in Gentoo Handbook (amd64)
root #
tar xpvf stage3-*.tar.xz --xattrs-include='*.*' --numeric-owner
Assemble a Gentoo system from scratch
- Prepare media (microSD card for u-boot, kernel, initramfs; optional additional media for rootfs -- project depicted at top of article employs a 128G pcie NVMe via USB stick, luks encrypted, with lvm volumes for Gentoo rootfs.)
- Install u-boot, kernel, and initramfs to boot device; optionally use serial console to observe u-boot handoff to initramfs and kernel
- Install Gentoo rootfs as stage3 (see above; follow handbook install process all the way to boot and add local user. Tune make.conf for this board)
- Install eselect-repository and add joetoo repo
- Install dev-embedded/sbc-headless-meta::joetoo with USE including "joetoo rk3399-tinker-2"
- Verify CPU_FLAGS and COMMON_FLAGS with cpuid2cpuflags and resolve-march-native
- Install dev-util/joetoolkit::joetoo and use get_my_cflags.sh to double-check
- This will select joetoo-base/joetoo-meta::joetoo which installs standard software according to USE flags, and basic joetoo .conf files for these software packages. ==> configure those
- update with app-portage/jus::joetoo (joetoo update sequence)
- rebuild the entire system with rus (rebuild update sequence) script from app-portage/jus
(to do) See also this similar work for a different board -- User:Brendlefly62/Rockchip_RK3288_Asus_Tinker_Board_S/Assemble_a_Gentoo_System