• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1name: CI NMake
2on: [push, pull_request]
3jobs:
4  ci-cmake:
5    name: ${{ matrix.name }}
6    runs-on: ${{ matrix.os }}
7    strategy:
8      fail-fast: false
9      matrix:
10        include:
11          - name: Windows NMake x86
12            os: windows-2022
13            makefile: win32/Makefile.msc
14            vc-vars: x86
15
16          - name: Windows NMake x64 compat
17            os: windows-2022
18            makefile: win32/Makefile.msc
19            vc-vars: x86_amd64
20            additional-args: ZLIB_COMPAT=yes
21
22          - name: Windows NMake x64 Symbol Prefix
23            os: windows-2022
24            makefile: win32/Makefile.msc
25            vc-vars: x86_amd64
26            additional-args: SYMBOL_PREFIX=zTest_
27
28          - name: Windows NMake x64 Symbol Prefix Compat
29            os: windows-2022
30            makefile: win32/Makefile.msc
31            vc-vars: x86_amd64
32            additional-args: ZLIB_COMPAT=yes SYMBOL_PREFIX=zTest_
33
34          - name: Windows NMake x64
35            os: windows-2022
36            makefile: win32/Makefile.msc
37            vc-vars: x86_amd64
38
39          - name: Windows NMake ARM No Test
40            os: windows-2022
41            makefile: win32/Makefile.arm
42            vc-vars: x86_arm
43
44          - name: Windows NMake ARM64 No Test
45            os: windows-2022
46            makefile: win32/Makefile.a64
47            vc-vars: x86_arm64
48
49    steps:
50    - name: Checkout repository
51      uses: actions/checkout@v2
52
53    - name: Compile source code
54      shell: cmd
55      run: |
56        call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.vc-vars }}
57        nmake -f ${{ matrix.makefile }} ${{ matrix.additional-args }}
58
59    - name: Run test cases
60      shell: cmd
61      # Don't run tests on Windows ARM
62      if: contains(matrix.vc-vars, 'arm') == false
63      run: |
64        call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.vc-vars }}
65        nmake -f ${{ matrix.makefile }} ${{ matrix.additional-args }} test
66        nmake -f ${{ matrix.makefile }} ${{ matrix.additional-args }} testdll
67