54 lines
1.2 KiB
YAML
54 lines
1.2 KiB
YAML
name: Build Windows
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
#push:
|
|
# branches: [ "main" ]
|
|
#pull_request:
|
|
# branches: [ "main" ]
|
|
|
|
env:
|
|
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
|
|
BUILD_TYPE: Release
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: windows-latest
|
|
|
|
defaults:
|
|
run:
|
|
working-directory: src
|
|
shell: bash
|
|
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: msys2/setup-msys2@v2
|
|
with:
|
|
install: >-
|
|
mingw-w64-x86_64-toolchain
|
|
mingw-w64-x86_64-cmake
|
|
msystem: mingw64
|
|
release: false
|
|
|
|
- name: Install Qt
|
|
uses: jurplel/install-qt-action@v3
|
|
with:
|
|
aqtversion: '==3.1.*'
|
|
version: '5.14.2'
|
|
host: 'windows'
|
|
target: 'desktop'
|
|
arch: 'win32_mingw73'
|
|
|
|
- name: Configure CMake
|
|
shell: msys2 {0}
|
|
run: cmake -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_PREFIX_PATH="${{env.Qt5_Dir}}/lib/cmake/" -DQt5_DIR=${{env.Qt5_Dir}}/lib/cmake/Qt5/ -G "CodeBlocks - MinGW Makefiles" -B '${{github.workspace}}'/build
|
|
|
|
- name: Build
|
|
run: cmake --build "${{github.workspace}}\build" --config ${{env.BUILD_TYPE}}
|
|
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: 'windows-build'
|
|
path: 'build/*'
|