forked from PlotJuggler/PlotJuggler
-
Notifications
You must be signed in to change notification settings - Fork 1
98 lines (84 loc) · 3.53 KB
/
Copy pathubuntu.yaml
File metadata and controls
98 lines (84 loc) · 3.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: ubuntu
on:
push:
branches:
- main
tags:
- '[0-9]+.[0-9]+.[0-9]+'
pull_request:
types: [opened, synchronize]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
ubuntu-build:
runs-on: ${{ matrix.ubuntu-distro }}
strategy:
fail-fast: false
matrix:
include:
- ubuntu-distro: ubuntu-22.04
arch: x86_64
- ubuntu-distro: ubuntu-22.04-arm
arch: aarch64
steps:
- name: Sync repository
uses: actions/checkout@v6
- name: Cache apt packages
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: software-properties-common qtbase5-dev libqt5svg5-dev libqt5websockets5-dev libqt5serialport5-dev libqt5opengl5-dev libqt5x11extras5-dev libprotoc-dev ccache libmosquitto-dev ca-certificates lsb-release wget libcurl4-openssl-dev
version: 2.1
- name: Install Apache Arrow for Parquet support
shell: bash
run: |
wget https://packages.apache.org/artifactory/arrow/$(lsb_release --id --short | tr 'A-Z' 'a-z')/apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb
sudo apt install -y -V ./apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb
sudo apt update
sudo apt install -y -V libarrow-dev libparquet-dev
- name: Prepare ccache
shell: bash
run: |
mkdir -p ${{ runner.temp }}/ccache/tmp
- name: Save ccache folder
uses: actions/cache@v5
with:
path: ${{ runner.temp }}/ccache
key: ${{ runner.os }}-${{ matrix.ubuntu-distro }}
- name: Build Plotjuggler
shell: bash
working-directory: ${{ github.workspace }}
env:
CCACHE_DIR: ${{ runner.temp }}/ccache
run: |
cmake . -B build -DCMAKE_BUILD_TYPE=Release -DPJ_INSTALLATION="appimage" \
-DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DPJ_PLUGINS_DIRECTORY="bin"
cmake --build build
- name: Build AppImage
working-directory: ${{ github.workspace }}
if: startsWith(github.ref, 'refs/tags/')
run: |
wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-${{ matrix.arch }}.AppImage
wget https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-${{ matrix.arch }}.AppImage
chmod +x linuxdeploy*.AppImage
mkdir -p AppDir/usr/bin
cp -v build/bin/* AppDir/usr/bin
./linuxdeploy-${{ matrix.arch }}.AppImage --appdir=AppDir \
-d ./io.plotjuggler.PlotJuggler.desktop \
-i ./plotjuggler.png \
--plugin qt --output appimage
mv PlotJuggler-${{ matrix.arch }}.AppImage PlotJuggler-${{ github.ref_name }}-${{ matrix.arch }}.AppImage
- name: Upload AppImage
uses: actions/upload-artifact@v7
if: startsWith(github.ref, 'refs/tags/')
with:
name: PlotJuggler-${{ github.ref_name }}-${{ matrix.arch }}.AppImage
path: PlotJuggler-${{ github.ref_name }}-${{ matrix.arch }}.AppImage
- name: Upload to Release
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
with:
files: PlotJuggler-${{ github.ref_name }}-${{ matrix.arch }}.AppImage
generate_release_notes: true
fail_on_unmatched_files: false