@@ -2,7 +2,12 @@ name: GitHub Actions
22
33on : [push]
44jobs :
5- build-windows-i686 :
5+ build-windows :
6+ strategy :
7+ matrix :
8+ include :
9+ - { sys: mingw64, env: x86_64, arch: amd64}
10+ - { sys: mingw32, env: i686, arch: 386}
611 runs-on : windows-latest
712 steps :
813 - name : Check out repository code
@@ -11,24 +16,24 @@ jobs:
1116 uses : msys2/setup-msys2@v2
1217 with :
1318 update : true
14- msystem : MINGW32
19+ msystem : ${{ matrix.sys }}
1520 install : |
16- mingw-w64-i686 -toolchain
17- mingw-w64-i686 -go
21+ mingw-w64-${{ matrix.env }} -toolchain
22+ mingw-w64-${{ matrix.env }} -go
1823 - name : Build executables
1924 env :
20- GOARCH : 386
25+ GOARCH : ${{ matrix.arch }}
2126 CGO_ENABLED : 1
2227 shell : msys2 {0}
2328 run : |
2429 mkdir build
25- i686 -w64-mingw32-gcc -o build/test-discon .dll test-discon/test-discon.c --shared -g
26- i686 -w64-mingw32-gcc -o build/test-app .exe test-app/test-app.c -g
27- go build -o build/discon-server .exe discon-wrapper/discon-server
28- go build -buildmode=c-shared -o build/discon-client .exe discon-wrapper/discon-client
30+ ${{ matrix.env }} -w64-mingw32-gcc -o build/test-discon_${{ matrix.arch }} .dll test-discon/test-discon.c --shared -g
31+ ${{ matrix.env }} -w64-mingw32-gcc -o build/test-app_${{ matrix.arch }} .exe test-app/test-app.c -g
32+ go build -o build/discon-server_${{ matrix.arch }} .exe discon-wrapper/discon-server
33+ go build -buildmode=c-shared -o build/discon-client_${{ matrix.arch }} .exe discon-wrapper/discon-client
2934 - uses : actions/upload-artifact@v4
3035 with :
31- name : windows-binaries-i686
36+ name : windows-binaries-${{ matrix.arch }}
3237 path : build/*
3338
3439 # build-and-test-linux:
0 commit comments