Skip to content

Commit bcacc4e

Browse files
committed
Use MSYS2 to build GNU libiconv on Windows CI
1 parent c45bffb commit bcacc4e

File tree

2 files changed

+15
-11
lines changed

2 files changed

+15
-11
lines changed

.github/workflows/win.yml

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,14 @@ jobs:
2323
- name: Enable Developer Command Prompt
2424
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
2525

26-
- name: Set up Cygwin
27-
uses: cygwin/cygwin-install-action@f61179d72284ceddc397ed07ddb444d82bf9e559 # v5
26+
- name: Set up MSYS2
27+
id: msys2
28+
uses: msys2/setup-msys2@61f9e5e925871ba6c9e3e8da24ede83ea27fa91f # v2.27.0
2829
with:
29-
packages: make
30-
install-dir: C:\cygwin64
31-
add-to-path: false
30+
msystem: UCRT64
31+
update: true
32+
install: >-
33+
make
3234
3335
- name: Download Crystal source
3436
uses: actions/checkout@v4
@@ -102,12 +104,14 @@ jobs:
102104
- name: Enable Developer Command Prompt
103105
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
104106

105-
- name: Set up Cygwin
106-
uses: cygwin/cygwin-install-action@f61179d72284ceddc397ed07ddb444d82bf9e559 # v5
107+
- name: Set up MSYS2
108+
id: msys2
109+
uses: msys2/setup-msys2@61f9e5e925871ba6c9e3e8da24ede83ea27fa91f # v2.27.0
107110
with:
108-
packages: make
109-
install-dir: C:\cygwin64
110-
add-to-path: false
111+
msystem: UCRT64
112+
update: true
113+
install: >-
114+
make
111115
112116
- name: Download Crystal source
113117
uses: actions/checkout@v4

etc/win-ci/build-iconv.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ rm libiconv.tar.gz
1414

1515
Run-InDirectory $BuildTree {
1616
$env:CHERE_INVOKING = 1
17-
& 'C:\cygwin64\bin\bash.exe' --login "$PSScriptRoot\cygwin-build-iconv.sh" "$Version" "$(if ($Dynamic) { 1 })"
17+
& 'C:\msys64\usr\bin\bash.exe' --login "$PSScriptRoot\cygwin-build-iconv.sh" "$Version" "$(if ($Dynamic) { 1 })"
1818
if (-not $?) {
1919
Write-Host "Error: Failed to build libiconv" -ForegroundColor Red
2020
Exit 1

0 commit comments

Comments
 (0)