-
-
Notifications
You must be signed in to change notification settings - Fork 26
141 lines (115 loc) · 3.4 KB
/
build.yml
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
name: guppy build
on:
push:
branches: [ "dev", "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: write
jobs:
build:
strategy:
matrix:
include:
- arch: mips-linux-gnu-
theme: zbolt
small: false
rotate: true
calibrate: false
asset: guppyscreen-zbolt
- arch: mips-linux-gnu-
theme: material
small: false
rotate: true
calibrate: false
asset: guppyscreen
- arch: mips-linux-gnu-
theme: material
small: true
rotate: false
calibrate: true
asset: guppyscreen-smallscreen
- arch: aarch64-none-linux-gnu-
theme: material
small: false
rotate: false
calibrate: true
asset: guppyscreen-arm
runs-on: ubuntu-22.04
container:
image: ballaswag/guppydev:latest
options: --user 1001
env:
CROSS_COMPILE: ${{ matrix.arch }}
CC: ${{ matrix.arch }}
CXX: ${{ matrix.arch }}
GUPPY_THEME: ${{ matrix.theme }}
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- if: ${{ ! startsWith(github.ref, 'refs/tags/') }}
name: set guppyscreen nightly version
run: |
echo "GUPPYSCREEN_VERSION=nightly-${{ github.sha }}" >> $GITHUB_ENV
- if: startsWith(github.ref, 'refs/tags/')
name: set guppyscreen nightly version
run: |
echo "GUPPYSCREEN_VERSION=${{ github.ref_name }}" >> $GITHUB_ENV
- if: matrix.small
name: export screen size
run: |
echo "GUPPY_SMALL_SCREEN=${{ matrix.small }}" >> $GITHUB_ENV
- if: matrix.rotate
name: export screen rotate
run: |
echo "GUPPY_ROTATE=${{ matrix.rotate }}" >> $GITHUB_ENV
- if: matrix.calibrate
name: export touch calibrate
run: |
echo "EVDEV_CALIBRATE=${{ matrix.calibrate }}" >> $GITHUB_ENV
- name: patch lv_drivers
run: |
git apply ../patches/0001-lv_driver_fb_ioctls.patch
working-directory: ./lv_drivers
- name: patch fmt in spdlog
run: |
git apply ../patches/0002-spdlog_fmt_initializer_list.patch
working-directory: ./spdlog
- name: patch dpi text scale in lvgl
run: |
git apply ../patches/0003-lvgl-dpi-text-scale.patch
working-directory: ./lvgl
- name: make wpaclient
run: make wpaclient
- name: make libhv
run: make libhv.a
- name: make libspdlog
run: make libspdlog.a
- name: make guppyscreen
run: make -j
- name: make kd_graphic_mode
run: make kd_graphic_mode
- name: package release
run: |
chmod +x ./release.sh
./release.sh ${{ matrix.asset }}
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.asset }}
path: ./${{ matrix.asset }}.tar.gz
- name: nightly release
uses: softprops/action-gh-release@v2
with:
prerelease: true
name: nightly
tag_name: nightly
files: ${{ matrix.asset }}.tar.gz
fail_on_unmatched_files: true
- name: stable release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
files: ${{ matrix.asset }}.tar.gz
generate_release_notes: true
fail_on_unmatched_files: true