Fix video being extremely slow when OSD is disabled via command line #69
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: Build | |
on: | |
push: | |
branches: | |
- master | |
tags: | |
- '*' | |
pull_request: | |
branches: | |
- master | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y qemu-user-static | |
# https://cloud.debian.org/images/cloud/bullseye/latest/debian-11-generic-arm64.tar.xz | |
# https://github.com/OpenIPC/sbc-groundstations/releases/download/zero3w-v1.7.0/radxaZero3wrev2.img.xz | |
host=https://cloud.debian.org/images/cloud/bullseye | |
release=latest | |
system=debian-11-generic-arm64.tar | |
wget -nv ${host}/${release}/${system}.xz | |
# unxz -T4 ${system}.xz | |
tar -xf ${system}.xz | |
output=output | |
mkdir $output | |
# device=$(sudo losetup -P --show -f ${system}) | |
# sudo mount ${device}p3 $output | |
device=$(sudo losetup -P --show -f disk.raw) | |
sudo mount ${device}p1 $output | |
cat > build.sh << EOL | |
#!/bin/bash | |
cd /home | |
# install radxa APT repo, see https://radxa-repo.github.io/bullseye/ | |
keyring="/home/keyring.deb" | |
version="\$(curl -L https://github.com/radxa-pkg/radxa-archive-keyring/releases/latest/download/VERSION)" | |
curl -L --output "\$keyring" "https://github.com/radxa-pkg/radxa-archive-keyring/releases/download/\${version}/radxa-archive-keyring_\${version}_all.deb" | |
dpkg -i \$keyring | |
tee /etc/apt/sources.list.d/70-radxa.list <<< "deb [signed-by=/usr/share/keyrings/radxa-archive-keyring.gpg] https://radxa-repo.github.io/bullseye/ bullseye main" | |
tee /etc/apt/sources.list.d/80-rockchip.list <<< "deb [signed-by=/usr/share/keyrings/radxa-archive-keyring.gpg] https://radxa-repo.github.io/bullseye rockchip-bullseye main" | |
apt-get update | |
apt-get install -y cmake g++ git pkg-config librockchip-mpp-dev libcairo-dev libdrm-dev libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev libspdlog-dev nlohmann-json3-dev | |
apt clean | |
cmake -B build | |
cmake --build build -j4 --target install | |
EOL | |
cat > run.sh <<EOL | |
#!/bin/bash | |
LD_LIBRARY_PATH=/usr/local/lib/ /usr/local/bin/pixelpilot \$@ | |
EOL | |
chmod 755 build.sh run.sh | |
sudo cp -r build.sh run.sh CMakeLists.txt pixelpilot_config.h.in src $output/home | |
sudo rm $output/etc/resolv.conf | |
echo nameserver 1.1.1.1 | sudo tee -a $output/etc/resolv.conf | |
sudo chroot $output /home/build.sh | |
sudo chroot $output /home/run.sh --version | |
sudo cp $output/home/build/pixelpilot . | |
- name: Versioned release | |
if: startsWith(github.ref, 'refs/tags/') | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: pixelpilot | |
- name: Upload latest | |
if: github.event_name != 'pull_request' | |
uses: softprops/action-gh-release@v2 | |
with: | |
tag_name: latest | |
files: pixelpilot |