aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/windows.yml66
-rw-r--r--.github/workflows/windows_test.yml46
2 files changed, 66 insertions, 46 deletions
diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml
new file mode 100644
index 0000000..421ebf3
--- /dev/null
+++ b/.github/workflows/windows.yml
@@ -0,0 +1,66 @@
1# GitHub Actions workflow to run tests on Windows.
2name: "Windows"
3
4on:
5 push: {}
6 pull_request: {}
7 schedule:
8 - cron: "0 0 * * 0" # At 00:00 weekly on Sunday.
9
10jobs:
11 test:
12 name: "${{ matrix.os }}/${{ matrix.arch }}${{ matrix.generator && ' (' + matrix.generator + ')' || '' }}"
13 runs-on: "${{ matrix.os }}"
14 permissions:
15 contents: read
16 strategy:
17 fail-fast: false
18 matrix:
19 os: ["windows-2022", "windows-2019"]
20 arch: ["ARM64", "x64", "Win32"]
21 include:
22 - os: "windows-2022"
23 generator: "Visual Studio 17 2022"
24 - os: "windows-2019"
25 generator: "Visual Studio 16 2019"
26 steps:
27 - name: "Checkout repository"
28 uses: actions/checkout@v4
29
30 - name: "Setup MSYS2"
31 uses: msys2/setup-msys2@v2
32 with:
33 update: true
34 install: >-
35 autoconf
36 automake
37 diffutils
38 libtool
39 gcc
40 git
41 patch
42 perl
43
44 - name: "Setup"
45 shell: msys2 {0}
46 run: ./autogen.sh
47
48 - name: "Configure CMake"
49 shell: cmd
50 run: cmake -Bbuild -G "${{ matrix.generator }}" -A ${{ matrix.arch }} -DCMAKE_INSTALL_PREFIX=../local
51
52 - name: "Build"
53 shell: cmd
54 run: cmake --build build --config Release
55
56 - name: "Test"
57 if: matrix.arch != 'ARM64'
58 shell: cmd
59 run: ctest --test-dir build -C Release --output-on-failure
60
61 - name: "Upload build artifacts"
62 if: always()
63 uses: actions/upload-artifact@v4
64 with:
65 name: "${{ matrix.os }}-${{ matrix.arch }}-build-results"
66 path: "build"
diff --git a/.github/workflows/windows_test.yml b/.github/workflows/windows_test.yml
deleted file mode 100644
index bac948e..0000000
--- a/.github/workflows/windows_test.yml
+++ /dev/null
@@ -1,46 +0,0 @@
1name: windows_ci
2
3on: [push, pull_request]
4
5jobs:
6 build-native:
7 strategy:
8 matrix:
9 os: [windows-2019, windows-2022]
10 arch: [Win32, x64, ARM64]
11 include:
12 - generator: "Visual Studio 16 2019"
13 os: windows-2019
14 - generator: "Visual Studio 17 2022"
15 os: windows-2022
16 runs-on: ${{ matrix.os }}
17 continue-on-error: false
18 name: ${{ matrix.os }} - ${{ matrix.arch }}
19 steps:
20 - uses: msys2/setup-msys2@v2
21 with:
22 update: true
23 install: >-
24 autoconf
25 automake
26 diffutils
27 libtool
28 gcc
29 git
30 patch
31 perl
32 - uses: actions/checkout@main
33 - shell: msys2 {0}
34 run: ./autogen.sh
35 - shell: cmd
36 run: cmake -Bbuild -G "${{ matrix.generator }}" -A ${{ matrix.arch }} -DCMAKE_INSTALL_PREFIX=../local
37 - shell: cmd
38 run: cmake --build build --config Release
39 - shell: cmd
40 if: ${{ matrix.arch != 'ARM64' }}
41 run: ctest --test-dir build -C Release --output-on-failure
42 - uses: actions/upload-artifact@v3
43 if: always()
44 with:
45 name: windows-build-results-${{ matrix.os }}-${{ matrix.arch }}
46 path: build