Group: Hardware/FSDG distributions/PureOS

From LibrePlanet
Jump to: navigation, search
(How to install PureOS on an arm64 SBC)
Line 1: Line 1:
 +
== u-boot ==
 +
U-boot has a standard for booting distributions. The easiest way to configure your distribution to boot with u-boot is to create an extlinux.conf configuration file as explaned below. U-boot will then look for it in /boot/extlinux/extlinux.conf (and probably /extlinux/extlinux.conf too) on each partition that it can access.
 +
 
== How to install PureOS on an arm64 SBC ==
 
== How to install PureOS on an arm64 SBC ==
 
{{stub}}
 
{{stub}}
Line 5: Line 8:
 
  # udisksctl loop-setup -f storage.img
 
  # udisksctl loop-setup -f storage.img
 
  # mkdir rootfs
 
  # mkdir rootfs
 +
# mkfs.ext4 -O ^metadata_csum -O ^64bit /dev/loop0p1
 
  # mount /dev/loop0p1 rootfs
 
  # mount /dev/loop0p1 rootfs
 
  # mkdir -p rootfs/usr/bin
 
  # mkdir -p rootfs/usr/bin

Revision as of 07:44, 27 October 2019

u-boot

U-boot has a standard for booting distributions. The easiest way to configure your distribution to boot with u-boot is to create an extlinux.conf configuration file as explaned below. U-boot will then look for it in /boot/extlinux/extlinux.conf (and probably /extlinux/extlinux.conf too) on each partition that it can access.

How to install PureOS on an arm64 SBC

# qemu-img create -f raw storage.img 2G
# fdisk storage.img # create 1 partition
# udisksctl loop-setup -f storage.img
# mkdir rootfs
# mkfs.ext4 -O ^metadata_csum -O ^64bit /dev/loop0p1
# mount /dev/loop0p1 rootfs
# mkdir -p rootfs/usr/bin
# debootstrap --foreign --arch arm64 amber rootfs https://repo.puri.sm/pureos 
# cp /usr/bin/qemu-aarch64-static rootfs/usr/bin
# LANG=C.UTF-8 chroot rootfs qemu-aarch64-static /bin/bash
# export TERM=xterm-color
# /debootstrap/debootstrap --second-stage

You then need to create the extlinux.conf file in /boot/extlinux/extlinux.conf with the following content:

menu title Welcome to U-Boot with Extlinux support!

timeout 10

label PureOS GNU/Linux-libre, linux-libre kernel
        kernel /vmlinuz
        append loglevel=8 root=/dev/mmcblk0p1 rw
        fdtdir /usr/lib/linux-image-5.2.0-3-arm64/
        initrd /initrd.img

TODO

  • Add a symlink for /usr/lib/linux-image-5.2.0-3-arm64/ to /ftddir or something like that in Debian and backport it to FSDG distributions that support architecture with devicetree like PureOS