forked from crystal-lang/crystal
-
Notifications
You must be signed in to change notification settings - Fork 1
140 lines (117 loc) · 4.04 KB
/
mingw-w64.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
name: MinGW-w64 CI
on: [push, pull_request]
permissions: {}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}
env:
SPEC_SPLIT_DOTS: 160
jobs:
x86_64-mingw-w64-build:
runs-on: windows-2022
steps:
- name: Setup MSYS2
id: msys2
uses: msys2/setup-msys2@d44ca8e88d8b43d56cf5670f91747359d5537f97 # v2.26.0
with:
msystem: UCRT64
update: true
install: >-
git
make
mingw-w64-ucrt-x86_64-pkgconf
mingw-w64-ucrt-x86_64-llvm
mingw-w64-ucrt-x86_64-crystal
- name: Disable CRLF line ending substitution
run: |
git config --global core.autocrlf false
- name: Download Crystal source
uses: actions/checkout@v4
- name: Build Crystal
shell: msys2 {0}
run: make crystal interpreter=1 release=1
- name: Package Crystal
shell: msys2 {0}
run: make install install_dlls deref_symlinks=1 PREFIX="$(pwd)/crystal"
- name: Download shards release
uses: actions/checkout@v4
with:
repository: crystal-lang/shards
ref: v0.19.1
path: shards
- name: Build shards release
shell: msys2 {0}
working-directory: ./shards
run: make CRYSTAL=$(pwd)/../crystal/bin/crystal SHARDS=false release=1
- name: Package Shards
shell: msys2 {0}
working-directory: ./shards
run: |
make install PREFIX="$(pwd)/../crystal"
# FIXME: remove after crystal-lang/shards#668
ldd bin/shards.exe | grep -iv ' => /c/windows/system32' | sed 's/.* => //; s/ (.*//' | xargs -t -i /usr/bin/install -m 0755 '{}' "$(pwd)/../crystal/bin/"
- name: Upload Crystal executable
uses: actions/upload-artifact@v4
with:
name: x86_64-mingw-w64-crystal
path: crystal
x86_64-mingw-w64-test-stdlib:
runs-on: windows-2022
steps:
- name: Setup MSYS2
id: msys2
uses: msys2/setup-msys2@d44ca8e88d8b43d56cf5670f91747359d5537f97 # v2.26.0
with:
msystem: UCRT64
update: true
install: >-
git
make
mingw-w64-ucrt-x86_64-pkgconf
mingw-w64-ucrt-x86_64-llvm
mingw-w64-ucrt-x86_64-crystal
- name: Disable CRLF line ending substitution
run: |
git config --global core.autocrlf false
- name: Download Crystal source
uses: actions/checkout@v4
- name: Run stdlib specs
shell: msys2 {0}
run: |
export CRYSTAL_SPEC_COMPILER_BIN="$(which crystal.exe)"
make std_spec
x86_64-mingw-w64-test-compiler:
runs-on: windows-2022
steps:
- name: Setup MSYS2
id: msys2
uses: msys2/setup-msys2@d44ca8e88d8b43d56cf5670f91747359d5537f97 # v2.26.0
with:
msystem: UCRT64
update: true
install: >-
git
make
mingw-w64-ucrt-x86_64-pkgconf
mingw-w64-ucrt-x86_64-llvm
mingw-w64-ucrt-x86_64-crystal
- name: Disable CRLF line ending substitution
run: |
git config --global core.autocrlf false
- name: Download Crystal source
uses: actions/checkout@v4
- name: Run compiler specs
shell: msys2 {0}
run: |
export CRYSTAL_SPEC_COMPILER_BIN="$(which crystal.exe)"
make compiler_spec
- name: Run interpreter specs
shell: msys2 {0}
run: |
export CRYSTAL_SPEC_COMPILER_BIN="$(which crystal.exe)"
make interpreter_spec
- name: Run primitives specs
shell: msys2 {0}
run: |
export CRYSTAL_SPEC_COMPILER_BIN="$(which crystal.exe)"
make -o .build/crystal.exe primitives_spec # we know the compiler is fresh; do not rebuild it here