mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-22 04:40:30 +00:00
65 lines
2.4 KiB
YAML
65 lines
2.4 KiB
YAML
name: ARM builds
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- arm-build
|
|
|
|
jobs:
|
|
Build:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
arch: [armhf, arm64]
|
|
include:
|
|
- arch: armhf
|
|
repo: http://mirrordirector.raspbian.org/raspbian/
|
|
keyring: /etc/apt/trusted.gpg
|
|
- arch: arm64
|
|
repo: https://deb.debian.org/debian
|
|
keyring: /usr/share/keyrings/debian-archive-keyring.gpg
|
|
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- name: Prepare
|
|
run: |
|
|
sudo apt update
|
|
sudo apt install binfmt-support qemu qemu-user-static
|
|
- name: Cache Environment
|
|
id: cache-bootstrap
|
|
uses: actions/cache@v2
|
|
with:
|
|
path: 'chroot.tar'
|
|
key: cache-bootstrap-${{ matrix.arch }}-5
|
|
- name: Debootstrap
|
|
if: steps.cache-bootstrap.outputs.cache-hit != 'true'
|
|
run: |
|
|
sudo apt install debootstrap debian-archive-keyring
|
|
sudo mkdir chroot
|
|
wget http://archive.raspbian.org/raspbian.public.key -O - | sudo apt-key add -q
|
|
sudo qemu-debootstrap --keyring=${{ matrix.keyring }} --arch ${{ matrix.arch }} buster chroot ${{ matrix.repo }}
|
|
sudo cp $GITHUB_WORKSPACE/.github/scripts/Linux/arm/mksquashfs-compilation-fix.patch chroot
|
|
sudo .github/scripts/Linux/arm/bootstrap.sh ${{ matrix.arch }} chroot
|
|
sudo tar cf chroot.tar chroot # Create archive for caching. Needs to be created as root, therefore created manually.
|
|
- name: Extract Cached Environment
|
|
if: steps.cache-bootstrap.outputs.cache-hit == 'true'
|
|
run: sudo tar xf chroot.tar
|
|
- name: Build
|
|
run: |
|
|
sudo cp .github/scripts/Linux/arm/build.sh chroot
|
|
sudo chroot chroot /build.sh
|
|
- name: Upload Build
|
|
if: github.repository != 'CESNET/UltraGrid' || github.ref != 'refs/heads/arm-build'
|
|
uses: actions/upload-artifact@v1
|
|
with:
|
|
name: UltraGrid CI ${{ matrix.arch }} build
|
|
path: chroot/UltraGrid/UltraGrid-latest-${{ matrix.arch }}.AppImage
|
|
- name: Upload Release Asset
|
|
if: github.repository == 'CESNET/UltraGrid' && github.ref == 'refs/heads/arm-build'
|
|
run: |
|
|
sudo apt install jq
|
|
sudo .github/scripts/replace-asset.sh GITHUB_REPOSITORY=$GITHUB_REPOSITORY GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} continuous chroot/UltraGrid/UltraGrid-latest-${{ matrix.arch }}.AppImage application/x-appimage Linux%20${{ matrix.arch }}%20build
|
|
|
|
|
|
# vi: set expandtab sw=2:
|