Nightly Build #99
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Nightly Build | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
schedule: | |
# Run every day at 12:00 AM (nightly builds) | |
- cron: '0 12 * * *' | |
workflow_dispatch: | |
permissions: | |
contents: read | |
jobs: | |
build-native: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# Build native on both ubuntu 22.04 | |
- os: ubuntu-22.04 | |
runs-on: ${{ matrix.os }} | |
steps: | |
# Checkout code | |
- uses: actions/checkout@v3 | |
# Perform Phoenix Pro installation process | |
- name: Add Phoenix Pro to local apt | |
run: | | |
sudo curl -s --compressed -o /usr/share/keyrings/ctr-pubkey.gpg "https://deb.ctr-electronics.com/ctr-pubkey.gpg" | |
sudo curl -s --compressed -o /etc/apt/sources.list.d/ctr2023.list "https://deb.ctr-electronics.com/ctr2023.list" | |
# Update apt and install phoenixpro | |
- name: Install Phoenix Pro | |
run: | | |
sudo apt-get update | |
sudo apt-get install phoenix-pro cmake build-essential libsdl2-dev -y | |
# Build using CMake | |
- name: Build Example | |
run: | | |
mkdir build | |
cd build | |
cmake .. | |
make | |
build-arm: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# 32-bit arm on bullseye | |
- arch: armv7 | |
distro: bullseye | |
# 64-bit arm on bullseye | |
- arch: aarch64 | |
distro: bullseye | |
# 32-bit arm on bookworm | |
- arch: none | |
distro: none | |
base_image: arm32v7/debian:bookworm | |
# 64-bit arm on bookworm | |
- arch: none | |
distro: none | |
base_image: arm64v8/debian:bookworm | |
# 32-bit arm on ubuntu 20.04 (Seems to have problems compiling despite it working fine on real hardware) | |
#- arch: armv7 | |
# distro: ubuntu20.04 | |
# 64-bit arm on ubuntu 20.04 | |
- arch: aarch64 | |
distro: ubuntu20.04 | |
# 32-bit arm on ubuntu 22.04 | |
- arch: armv7 | |
distro: ubuntu22.04 | |
# 64-bit arm on ubuntu 22.04 | |
- arch: aarch64 | |
distro: ubuntu22.04 | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout code | |
- uses: actions/checkout@v3 | |
# Do all the same steps as the above code, but all at once under the architecture | |
- uses: uraimo/run-on-arch-action@v2 | |
name: Build on arch | |
with: | |
arch: ${{ matrix.arch }} | |
distro: ${{ matrix.distro }} | |
base_image: ${{ matrix.base_image }} | |
# Not required, but speeds up builds by storing container images in | |
# a GitHub package registry. | |
githubToken: ${{ github.token }} | |
# Perform the installation in a cached state to speed up subsequent builds | |
install: | | |
apt-get update | |
apt-get install curl -y | |
curl -s --compressed -o /usr/share/keyrings/ctr-pubkey.gpg "https://deb.ctr-electronics.com/ctr-pubkey.gpg" | |
curl -s --compressed -o /etc/apt/sources.list.d/ctr2023.list "https://deb.ctr-electronics.com/ctr2023.list" | |
apt-get update | |
apt-get install phoenix-pro cmake build-essential libsdl2-dev -y | |
# Perform the necesary steps to build the example | |
run: | | |
mkdir build | |
cd build | |
cmake .. | |
make |