-
Notifications
You must be signed in to change notification settings - Fork 4
116 lines (98 loc) · 3 KB
/
advanced.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
name: Build toolchain variants
on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:
inputs:
binutils_branch:
description: 'Binutils branch to build'
required: false
default: 'woarm64'
gcc_branch:
description: 'GCC branch to build'
required: false
default: 'woarm64'
mingw_branch:
description: 'Mingw branch to build'
required: false
default: 'woarm64'
jobs:
build-toolchain:
runs-on: ubuntu-latest
strategy:
matrix:
target: [aarch64-w64-mingw32, x86_64-w64-mingw32]
crt: [msvcrt, ucrt]
env:
BINUTILS_REPO: ZacWalk/binutils-woarm64
BINUTILS_BRANCH: ${{ github.event.inputs.binutils_branch }}
BINUTILS_VERSION: binutils-master
GCC_REPO: ZacWalk/gcc-woarm64
GCC_BRANCH: ${{ github.event.inputs.gcc_branch }}
GCC_VERSION: gcc-master
MINGW_REPO: ZacWalk/mingw-woarm64
MINGW_BRANCH: ${{ github.event.inputs.mingw_branch }}
MINGW_VERSION: mingw-w64-master
TARGET: ${{ matrix.target }}
CRT: ${{ matrix.crt }}
INSTALL_PATH: ${{ github.workspace }}/cross
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
path: ${{ github.workspace }}
- name: Checkout binutils
uses: actions/checkout@v4
with:
repository: ${{ env.BINUTILS_REPO }}
ref: ${{ env.BINUTILS_BRANCH }}
path: ${{ github.workspace }}/code/${{ env.BINUTILS_VERSION }}
- name: Checkout GCC
uses: actions/checkout@v4
with:
repository: ${{ env.GCC_REPO }}
ref: ${{ env.GCC_BRANCH }}
path: ${{ github.workspace }}/code/${{ env.GCC_VERSION }}
- name: Checkout MinGW
uses: actions/checkout@v4
with:
repository: ${{ env.MINGW_REPO }}
ref: ${{ env.MINGW_BRANCH }}
path: ${{ github.workspace }}/code/${{ env.MINGW_VERSION }}
- name: Install dependencies
run: |
.github/scripts/install-dependencies.sh
- name: Install libraries
run: |
.github/scripts/install-libraries.sh
- name: Build binutils
run: |
.github/scripts/build-binutils.sh
- name: Build MinGW headers
run: |
.github/scripts/build-mingw-headers.sh
- name: Build GCC
run: |
.github/scripts/build-gcc.sh
- name: Build MinGW CRT
run: |
.github/scripts/build-mingw-crt.sh
- name: Build libgcc
run: |
.github/scripts/build-libgcc.sh
- name: Build MinGW
run: |
.github/scripts/build-mingw.sh
- name: Build GCC libs
run: |
.github/scripts/build-gcc-libs.sh
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: ${{ env.TARGET }}-${{ env.CRT }}-toolchain
path: ${{ env.INSTALL_PATH }}
retention-days: 1