Raspberry Pi package #25
Workflow file for this run
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: Raspberry Pi package | |
on: | |
release: | |
types: [published] | |
jobs: | |
build: | |
permissions: write-all | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install rust dependencies | |
run: | | |
sudo apt update && sudo sudo apt install libwebkit2gtk-4.0-dev build-essential curl wget file libssl-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev -y | |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y | |
. "$HOME/.cargo/env" | |
rustup target add wasm32-unknown-unknown | |
rustup target add aarch64-unknown-linux-gnu | |
cargo install tauri-cli trunk | |
- name: Install cross-compilers | |
run: | | |
sudo apt update && sudo apt install gcc-aarch64-linux-gnu -y | |
sudo dpkg --add-architecture arm64 | |
mv .github/sources.list /etc/sudo apt/sources.list | |
sudo apt update && sudo apt upgrade -y | |
- name: Install arm dependencies | |
run: | | |
sudo sudo apt install libwebkit2gtk-4.0-dev:arm64 -y | |
sudo sudo apt install libssl-dev:arm64 -y | |
- name: Build application | |
run: | | |
export PKG_CONFIG_SYSROOT_DIR=/usr/aarch64-linux-gnu/ | |
cargo tauri build --config '{"package": {"version": "${{ github.event.release.tag_name }}"}}' --target aarch64-unknown-linux-gnu | |
- name: Upload Release Asset | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | |
gh release upload ${{ github.event.release.tag_name }} ${{ github.workspace }}/target/release/bundle/deb/home-display*.deb |