-
Notifications
You must be signed in to change notification settings - Fork 3
93 lines (81 loc) · 2.68 KB
/
cross.yaml
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
# .github/workflows/cross.yaml
name: Cross-Building
on:
workflow_dispatch:
push:
branches: [ "test" ]
jobs:
build:
strategy:
fail-fast: false
matrix:
target: [
"aarch64-linux-gnu", "arm-linux-gnueabihf",
"powerpc64le-linux-gnu",
"riscv64-linux-gnu",
"mipsel-linux-gnu", "mips64el-linux-gnuabi64", "mipsisa64r6el-linux-gnuabi64",
"alpha-linux-gnu"
]
compiler:
- { ver: "8", osver: "20.04" }
- { ver: "9", osver: "20.04" }
- { ver: "10", osver: "22.04" }
- { ver: "11", osver: "22.04" }
- { ver: "12", osver: "22.04" }
exclude:
- target: "mipsel-linux-gnu"
compiler: { ver: "8" }
- target: "mipsel-linux-gnu"
compiler: { ver: "11" }
- target: "mipsel-linux-gnu"
compiler: { ver: "12" }
- target: "mips64el-linux-gnuabi64"
compiler: { ver: "8" }
- target: "mips64el-linux-gnuabi64"
compiler: { ver: "11" }
- target: "mips64el-linux-gnuabi64"
compiler: { ver: "12" }
- target: "mipsisa64r6el-linux-gnuabi64"
compiler: { ver: "8" }
- target: "mipsisa64r6el-linux-gnuabi64"
compiler: { ver: "11" }
- target: "mipsisa64r6el-linux-gnuabi64"
compiler: { ver: "12" }
name: Build with ${{matrix.target}}-gcc-${{matrix.compiler.ver}}
runs-on: ubuntu-${{matrix.compiler.osver}}
defaults:
run:
shell: bash
steps:
- name: Machine Information
run: |
lscpu; free -h; df -h .
- name: System Information
run: |
date; uname -a; uptime; cat /etc/os-release; ls -C /boot || :
- name: Context Information
run: |
tty || :; id; printf %s\\n "$SHELL"; printf %s\\n "$PATH"; pwd
- name: Setup
run: |
set -x
sudo apt-get update
sudo apt-get install g++-${{matrix.compiler.ver}}-${{matrix.target}} qemu-user
- name: Build Tools Information
run: |
make --version; ${{matrix.target}}-gcc-${{matrix.compiler.ver}} --version
- name: Checkout
uses: actions/checkout@v4
- name: Run Make (and Check)
run: |
QEMU_LD_PREFIX=/usr/${{matrix.target}} \
make -j3 run \
GCC='${{matrix.target}}-gcc-${{matrix.compiler.ver}}' \
GXX='${{matrix.target}}-g++-${{matrix.compiler.ver}}' \
CFLAGS='-Wno-psabi -O3 -fno-stack-protector -fcf-protection=none' \
MARCH=
- name: Upload Results
uses: actions/upload-artifact@v4
with:
name: build-gcc-${{matrix.compiler.ver}}-${{matrix.target}}
path: build