-
Notifications
You must be signed in to change notification settings - Fork 109
129 lines (87 loc) · 2.72 KB
/
main.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
name: CI
on: [push]
jobs:
cache-submodule:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: env/setup.sh
- uses: ./.github/actions/submodule
build-lnx-srv:
needs: [cache-submodule]
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# XXX: armhf is missing rcrt1.o
machine: [x86_64, arm64]
steps:
- uses: actions/checkout@v4
- run: env/setup.sh
- uses: ./.github/actions/submodule
- run: env/setup-ndk.sh
- run: debug=crossndk make -j3 -C srv-daemon machine=${{ matrix.machine }}
- uses: actions/upload-artifact@v4
with:
name: orchidd-lnx-${{ matrix.machine }}
path: srv-daemon/out-lnx/${{ matrix.machine }}/orchidd
if: ${{ matrix.machine != 'x86_64' }}
- run: git status
build-lnx-dkr:
needs: [cache-submodule]
runs-on: ubuntu-latest
steps:
- run: sudo rm -rf /opt
- uses: actions/checkout@v4
- run: env/setup-git.sh
- uses: ./.github/actions/submodule
- run: cd srv-daemon && env/docker.sh -j3
build-lnx-bld:
needs: [cache-submodule]
runs-on: ubuntu-latest
steps:
- run: sudo rm -rf /opt
- uses: actions/checkout@v4
- run: docker build --build-arg GIT_REPOSITORY=https://github.com/${{ github.repository }}.git --build-arg GIT_COMMIT=${{ github.sha }} --build-arg GIT_SETUP=env/setup-git.sh -t orchidd:latest srv-docker
- run: docker save -o orchidd.tar orchidd:latest
- uses: actions/upload-artifact@v4
with:
name: orchidd-dkr
path: orchidd.tar
build-lnx-mac:
needs: [cache-submodule]
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- run: env/setup.sh
- uses: ./.github/actions/submodule
- uses: ./.github/actions/nerdctl
- run: env/setup-ndk.sh
- run: make -j3 -C srv-daemon target=lnx
- uses: actions/upload-artifact@v4
with:
name: orchidd-lnx-amd64
path: srv-daemon/out-lnx/x86_64/orchidd
build-lnx-bad:
needs: [cache-submodule]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: env/setup.sh
- uses: ./.github/actions/submodule
- run: make -j3 -C srv-daemon
build-lnx-all:
needs: [build-lnx-mac, build-lnx-bld]
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v4
with:
name: orchidd-dkr
- run: tar -xvf orchidd.tar
- run: tar -xvf "$(jq -r '.[0].Layers | .[]' manifest.json | tail -n1)"
- uses: actions/download-artifact@v4
with:
name: orchidd-lnx-amd64
- run: chmod +x orchidd
- run: diff -u <(./usr/sbin/orchidd --version) <(./orchidd --version)
- run: diff -u <(xxd usr/sbin/orchidd) <(xxd orchidd)