Skip to content

Commit b327689

Browse files
committed
windows ci
1 parent 6f18db7 commit b327689

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

.github/workflows/ci.yml

+14-14
Original file line numberDiff line numberDiff line change
@@ -50,19 +50,6 @@ jobs:
5050
musl-dev ncurses-dev perl tar xz \
5151
gtk+3.0-dev
5252
53-
- name: Install system dependencies (Ubuntu)
54-
if: runner.os == 'Linux' && !startsWith(matrix.container, 'alpine')
55-
run: sudo apt-get update && sudo apt-get install libgtk-3-dev
56-
57-
- name: Install system dependencies (Windows)
58-
if: ${{ startsWith(matrix.os, 'windows') }}
59-
uses: msys2/setup-msys2@v2
60-
with:
61-
path-type: inherit
62-
install: >-
63-
mingw-w64-x86_64-pkg-config
64-
mingw-w64-x86_64-gtk3
65-
6653
- name: Install system dependencies (macOS)
6754
if: runner.os == 'macOS'
6855
run: brew install cairo gtk+3 pkg-config
@@ -72,13 +59,26 @@ jobs:
7259
run: |
7360
printf 'package gtk\n flags: +have-quartz-gtk' >>cabal.project
7461
75-
7662
- name: Set up GHC ${{ matrix.ghc-version }}
7763
uses: haskell-actions/setup@v2
7864
id: setup
7965
with:
8066
ghc-version: ${{ matrix.ghc-version }}
8167

68+
# Taken from https://github.com/agda/agda/blob/8210048a50c35d8d6fd0ae7e5edd1699592fda6f/src/github/workflows/cabal.yml#L113C1-L124C85
69+
# See: https://github.com/haskell/text-icu/pull/86
70+
# pacman needs MSYS /usr/bin in PATH, but this breaks the latest cache action.
71+
# - https://github.com/actions/cache/issues/1073
72+
# MSYS' pkg-config needs MSYS /mingw64/bin which we can safely add to the PATH
73+
#
74+
- name: Install system dependencies (Windows)
75+
if: ${{ startsWith(matrix.os, 'windows') }}
76+
shell: pwsh
77+
run: |
78+
$env:PATH = "C:\msys64\usr\bin;$env:PATH"
79+
pacman --noconfirm -S msys2-keyring mingw-w64-x86_64-pkgconf mingw-w64-x86_64-gtk3
80+
echo "C:\msys64\mingw64\bin" | Out-File -FilePath "$env:GITHUB_PATH" -Append
81+
8282
- name: Enable static build (only on alpine)
8383
if: ${{ startsWith(matrix.container, 'alpine') }}
8484
run: |

0 commit comments

Comments
 (0)