1 name: windows-artifacts
5 branches: [ test_artifacts, win_artifacts ]
14 # see https://ariya.io/2020/07/on-github-actions-with-msys2
15 runs-on: windows-latest
16 # see https://github.com/msys2/setup-msys2
20 - { msystem: mingw64, env: x86_64, ziparch: win64 }
21 - { msystem: mingw32, env: i686, ziparch: win32 }
26 - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # tag=v3
27 - uses: msys2/setup-msys2@5beef6d11f48bba68b9eb503e3adc60b23c0cc36 # tag=v2
29 msystem: ${{ matrix.msystem }}
30 install: make zlib git p7zip mingw-w64-${{matrix.env}}-gcc
33 - name: display versions
38 - name: Building zlib to static link
40 git clone --depth 1 --branch v1.2.11 https://github.com/madler/zlib
41 make -C zlib -f win32/Makefile.gcc libz.a
43 - name: Building zstd programs
45 CPPFLAGS=-I../zlib LDFLAGS=../zlib/libz.a make -j allzstd MOREFLAGS=-static V=1
47 - name: Create artifacts
49 ./lib/dll/example/build_package.bat
50 mv bin/ zstd-${{ github.ref_name }}-${{matrix.ziparch}}/
51 7z a -tzip -mx9 zstd-${{ github.ref_name }}-${{matrix.ziparch}}.zip zstd-${{ github.ref_name }}-${{matrix.ziparch}}/
54 - name: Publish zstd-$VERSION-${{matrix.ziparch}}.zip
55 uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # tag=v4.3.1
57 path: ${{ github.workspace }}/zstd-${{ github.ref_name }}-${{matrix.ziparch}}.zip
58 name: zstd-${{ github.ref_name }}-${{matrix.ziparch}}.zip