# shallow clone clone_depth: 5 os: Visual Studio 2019 environment: # Tell msys2 to add mingw64 to the path MSYSTEM: MINGW64 # Tell msys2 to inherit the current directory when starting the shell CHERE_INVOKING: 1 matrix: - BUILD_TYPE: mingw platform: - x64 configuration: - Release install: - git submodule update --init --recursive - ps: | $dependencies = "mingw64/mingw-w64-x86_64-cmake mingw64/mingw-w64-x86_64-qt5-static" C:\msys64\usr\bin\bash -lc "pacman --noconfirm -S $dependencies" # (HACK) Link these libs to really static link qt C:\msys64\usr\bin\bash -lc "rm /mingw64/lib/libzstd.dll.a && link /mingw64/lib/libzstd.a /mingw64/lib/libzstd.dll.a" C:\msys64\usr\bin\bash -lc "rm /mingw64/lib/libz.dll.a && link /mingw64/lib/libz.a /mingw64/lib/libz.dll.a" # (HACK) ignore errors 0 before_build: - mkdir %BUILD_TYPE%_build - cd %BUILD_TYPE%_build - C:\msys64\usr\bin\bash.exe -lc "cmake -G 'MSYS Makefiles' -DCMAKE_BUILD_TYPE=Release -DMINGW_STATIC_BUILD=ON -DCOMPILE_WITH_DWARF=OFF .. 2>&1" - cd .. build_script: - C:\msys64\usr\bin\bash.exe -lc 'mingw32-make -j4 -C mingw_build/ 2>&1' after_build: - ps: | mkdir release mkdir release\dist C:\msys64\usr\bin\bash.exe -lc 'strip ./mingw_build/bin/threeSD.exe' Copy-Item .\mingw_build\bin\threeSD.exe -Destination release Copy-Item .\license.txt -Destination release Copy-Item .\README.md -Destination release Copy-Item .\dist\threeSDumper.gm9 -Destination release\dist $GITDATE = $(git show -s --date=short --format='%ad') -replace "-","" $GITREV = $(git show -s --format='%h') if ($env:APPVEYOR_REPO_TAG_NAME) { $BUILD_ZIP = "threeSD-windows-$env:APPVEYOR_REPO_TAG_NAME.zip" -replace " ", "" } else { $BUILD_ZIP = "threeSD-windows-$GITDATE-$GITREV.zip" -replace " ", "" } $env:BUILD_ZIP = $BUILD_ZIP 7z a $BUILD_ZIP release artifacts: - path: $(BUILD_ZIP) name: build deploy: provider: GitHub auth_token: secure: 4xdt1ZdE/ZgP2amG5Jr073yvbitMmdV0ts48wKBKEWpR6PJwDG3bR0Attvm9Mgv8 artifact: build on: branch: master APPVEYOR_REPO_NAME: zhaowenlan1779/threeSD APPVEYOR_REPO_TAG: true