-
Notifications
You must be signed in to change notification settings - Fork 2
51 lines (42 loc) · 1.53 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: build
on: [push, pull_request, workflow_dispatch]
jobs:
build:
# Skip building pull requests from the same repository
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != '${{ github.repository }}'
runs-on: windows-2022
strategy:
matrix:
os: [windows-2022]
env:
BUILD_TYPE: Release
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install ninja-build tool
uses: seanmiddleditch/gha-setup-ninja@v5
- name: Install Static Qt
run: |
Invoke-WebRequest https://github.com/microcai/static-build-qt6/releases/download/qt6_661_static_64/qt6_661_static_64.zip -OutFile .\qt6_661_static_64.zip
expand-archive -path "qt6_661_static_64.zip"
- name: Enable Developer Command Prompt
uses: ilammy/[email protected]
- name: Build
run: |
cmake -G Ninja -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} "-DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/install" -DCMAKE_PREFIX_PATH=qt6_661_static_64/Qt6_binaries -B build
cmake --build build
cmake --install build
- name: zip the result
run: |
cd install/bin
7z a eda-tool-win64.zip edatool.exe
- name: Release if on tags
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
files: install/bin/eda-tool-win64.zip
- name: Upload generic artifacts
uses: actions/[email protected]
with:
name: eda-tool-win64
path: install/bin