Skip to content
Snippets Groups Projects
Commit d7acecc6 authored by Sjoerd Simons's avatar Sjoerd Simons
Browse files

Add demo rpi3 hwpack

parent 85193876
No related branches found
No related tags found
No related merge requests found
{{ $architecture := or .architecture "armhf" }}
{{ $firmware_version := or .firmware_version "1.20190401" }}
{{ $type := or .type "minimal" }}
{{ $mirror := or .mirror "https://repositories.apertis.org/apertis/" }}
{{ $suite := or .suite "v2019dev0" }}
{{ $image := or .image (printf "apertis-rpi3-%s-%s-%s.img" $suite $type $architecture) }}
{{ $ospack := or .ospack (printf "ospack_%s-%s-%s" $suite $architecture $type) }}
architecture: {{ $architecture }}
actions:
# Download all needed proprietary stuff first
- action: download
url: https://github.com/raspberrypi/firmware/archive/{{ $firmware_version }}.tar.gz
unpack: true # Unpack downloaded file
name: firmware # name for usage directory with unpacked content in other actions
- action: unpack
description: Unpack {{ $ospack }}
compression: gz
file: {{ $ospack }}.tar.gz
- action: apt
recommends: false
packages:
- linux-image-armmp
- firmware-brcm80211
- u-boot-rpi
- u-boot-menu
# add firmware
- action: overlay
origin: firmware
source: firmware-{{ $firmware_version }}/boot
destination: /boot/firmware
- action: run
chroot: true
command: rm -rf /boot/firmware/kernel*.img /boot/firmware/*.dtb /boot/firmware/overlays
- action: run
chroot: true
command: cp -v /usr/lib/u-boot/rpi_3_32b/* /boot/firmware/
- action: run
description: Disable ribchester as it won't work on msdos partitioning
chroot: true
command: systemctl disable ribchester-core
- action: overlay
source: overlays/rpi3/fw-config
destination: /boot/firmware
- action: overlay
description: Add wireless firmware configuration
source: overlays/rpi3/firmware
destination: /lib/firmware
- action: overlay
description: Add wireless firmware configuration
source: overlays/rpi3/firmware
destination: /lib/firmware
- action: image-partition
imagename: {{ $image }}
imagesize: 1GB
partitiontype: msdos
mountpoints:
- mountpoint: /
partition: root
- mountpoint: /boot/firmware
partition: firmware
options: [ x-systemd.automount ]
partitions:
- name: firmware
fs: fat32
start: 0%
end: 64MB
- name: root
fs: ext4
start: 64MB
end: 100%
flags: [ boot ]
- action: filesystem-deploy
description: Deploying filesystem onto image
- action: overlay
description: Enable minimal cma area in u-boot-menu
source: overlays/rpi3/u-boot-menu
destination: /etc/default
- action: run
chroot: true
command: u-boot-update
# work around the Debos isssue in https://phabricator.apertis.org/T4308
- action: run
chroot: false
description: "Drop resolv.conf so the appropriate one gets created at runtime"
command: rm "${ROOTDIR}/etc/resolv.conf"
- action: run
postprocess: true
command: bmaptool create {{ $image }} > {{ $image }}.bmap
- action: run
postprocess: true
command: gzip -f {{ $image }}
This diff is collapsed.
# boot in 32 mode
#arm_control=0x200
enable_uart=1
kernel=u-boot.bin
U_BOOT_PARAMETERS=cma=128M
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment