forked from openscad/openscad
-
Notifications
You must be signed in to change notification settings - Fork 8
69 lines (67 loc) · 2.13 KB
/
windows.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: Windows(msys2) Experimental Tests
on:
push:
branches:
- master
pull_request:
workflow_dispatch:
inputs:
debug_enabled:
type: boolean
description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)'
required: false
default: false
jobs:
build:
strategy:
matrix:
qt: [ qt5, qt6 ]
runs-on: windows-latest
name: windows-latest ${{ matrix.qt }}
defaults:
run:
shell: msys2 {0}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup (detached) tmate session if enabled
uses: mxschmitt/action-tmate@v3
if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
with:
detached: true
- name: Setup MSYS2 Environment
uses: msys2/setup-msys2@v2
with:
msystem: UCRT64
update: true
- name: Install MSYS2 Dependencies
run: |
pwd
./scripts/msys2-install-dependencies.sh ${{ matrix.qt }}
- name: Install Mesa
uses: ssciwr/setup-mesa-dist-win@v2
with:
version: '22.1.7'
build-type: 'release-mingw'
- name: Build OpenSCAD
run: |
git submodule update --init --recursive
mkdir build && cd build
cmake .. -G"Ninja" -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DEXPERIMENTAL=ON -DSNAPSHOT=ON -DUSE_QT6=${{ matrix.qt == 'qt6' && 'ON' || 'OFF' }}
cmake --build . -j4
cmake --install . --prefix=.
- name: Run Test Suite
run: |
cd build
ctest -j4
- name: Setup (detached) tmate session if enabled
uses: mxschmitt/action-tmate@v3
if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
- name: Upload Test Result Report
uses: actions/upload-artifact@v4
if: ${{ always() }}
with:
name: Test Result Report (Windows ${{ matrix.qt }})
path: |
build/Testing/Temporary/*_report.html
build/Testing/Temporary/LastTest.log