Skip to content

Commit 2b12c9d

Browse files
authored
Merge pull request #186 from OpenBrickProtocolFoundation/185-windows-fix-dynamic-libraries-build
185 windows fix dynamic libraries build
2 parents e8a16dc + 3c69e89 commit 2b12c9d

File tree

113 files changed

+1349
-998
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

113 files changed

+1349
-998
lines changed

.github/workflows/build.yml

Lines changed: 9 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -15,72 +15,56 @@ jobs:
1515
fail-fast: false
1616
matrix:
1717
config:
18-
- name: Windows MSVC Release
18+
- name: Windows MSVC
1919
os: windows
2020
os-version: 2022
2121
environment: msvc
22-
buildtype: release
23-
library_type: static
2422
shell: pwsh
2523

26-
- name: Windows MingGW Release
24+
- name: Windows MingGW
2725
os: windows
2826
os-version: 2022
2927
environment: mingw
3028
architecture: x86_64
31-
buildtype: release
32-
library_type: static
3329
shell: 'msys2 {0}'
3430

35-
- name: Windows UCRT Release
31+
- name: Windows UCRT
3632
os: windows
3733
os-version: 2022
3834
environment: ucrt
3935
architecture: ucrt-x86_64
40-
buildtype: release
41-
library_type: static
4236
shell: 'msys2 {0}'
4337

44-
- name: Linux Release
38+
- name: Linux
4539
os: ubuntu
4640
os-version: 24.04
47-
buildtype: release
4841
use-clang: false
49-
library_type: shared
5042
shell: bash
5143

52-
- name: Linux Clang Release (libstdc++)
44+
- name: Linux Clang (libstdc++)
5345
os: ubuntu
5446
os-version: 24.04
55-
buildtype: release
5647
use-clang: true
5748
use-clang_stdlib: false
58-
library_type: shared
5949
shell: bash
6050

61-
- name: Linux Clang Release (libc++)
51+
- name: Linux Clang (libc++)
6252
os: ubuntu
6353
os-version: 24.04
64-
buildtype: release
6554
use-clang: true
6655
use-clang_stdlib: true
67-
library_type: shared
6856
shell: bash
6957

70-
- name: MacOS Release
58+
- name: MacOS
7159
os: macos
7260
os-version: 13
7361
arm: false
74-
buildtype: release
75-
library_type: shared
7662
shell: bash
7763

78-
- name: MacOS Release (Arm64)
64+
- name: MacOS (Arm64)
7965
os: macos
8066
os-version: 14
8167
arm: true
82-
buildtype: release
83-
library_type: shared
8468
shell: bash
8569

8670
defaults:
@@ -203,7 +187,7 @@ jobs:
203187
brew install sdl2 sdl2_ttf sdl2_mixer sdl2_image
204188
205189
- name: Configure
206-
run: meson setup build -Dbuildtype=${{ matrix.config.buildtype }} -Ddefault_library=${{ matrix.config.library_type }} -Dclang_libcpp=${{ ( ( matrix.config.os == 'ubuntu' && matrix.config.use-clang == true && matrix.config.use-clang_stdlib ) || matrix.config.os == 'macos' ) && 'enabled' || 'disabled' }}
190+
run: meson setup build -Dbuildtype=release -Ddefault_library=shared -Dclang_libcpp=${{ ( ( matrix.config.os == 'ubuntu' && matrix.config.use-clang == true && matrix.config.use-clang_stdlib ) || matrix.config.os == 'macos' ) && 'enabled' || 'disabled' }}
207191

208192
- name: Build
209193
run: meson compile -C build

.github/workflows/cpp-linter.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,13 @@ jobs:
2020
pip install meson --break-system-packages
2121
2222
- name: Setup Clang
23-
uses: egor-tensin/setup-clang@v1
24-
with:
25-
version: 19
26-
platform: x64
23+
run: |
24+
wget https://apt.llvm.org/llvm.sh
25+
chmod +x llvm.sh
26+
sudo ./llvm.sh 19
27+
echo "CC=clang-19" >> "$GITHUB_ENV"
28+
echo "CXX=clang++-19" >> "$GITHUB_ENV"
29+
echo "OBJC=clang-19" >> "$GITHUB_ENV"
2730
2831
- name: Prepare compile_commands.json
2932
run: |
@@ -44,7 +47,7 @@ jobs:
4447
database: build
4548
files-changed-only: ${{ github.event_name != 'workflow_dispatch' }}
4649
lines-changed-only: ${{ github.event_name != 'workflow_dispatch' }}
47-
thread-comments: true
50+
thread-comments: update
4851
tidy-checks: ''
4952
step-summary: true
5053
file-annotations: true

.github/workflows/installer.yml

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,43 +8,30 @@ on:
88

99
jobs:
1010
installer:
11-
name: ${{ matrix.config.name }}
12-
runs-on: ${{ matrix.config.os }}-${{ matrix.config.os-version }}
11+
name: Windows MSVC Installer
12+
runs-on: windows-2022
1313

14-
strategy:
15-
fail-fast: false
16-
matrix:
17-
config:
18-
- name: Windows MSVC Installer
19-
os: windows
20-
os-version: 2022
21-
msvc: true
22-
buildtype: release
23-
library_type: static
24-
shell: pwsh
2514
defaults:
2615
run:
27-
shell: ${{ matrix.config.shell }}
16+
shell: pwsh
2817

2918
steps:
3019
- uses: actions/checkout@v4
3120
with:
3221
fetch-depth: '0'
3322

3423
- name: Setup MSVC (Windows)
35-
if: matrix.config.os == 'windows' && matrix.config.msvc == true
3624
uses: TheMrMilchmann/setup-msvc-dev@v3
3725
with:
3826
arch: x64
3927
toolset: '14.41'
4028

4129
- name: Setup meson
42-
if: matrix.config.os != 'macos'
4330
run: |
4431
pip install meson
4532
4633
- name: Configure
47-
run: meson setup build -Dbuildtype=${{ matrix.config.buildtype }} -Ddefault_library=${{ matrix.config.library_type }} -Dclang_libcpp=${{ ( ( matrix.config.os == 'ubuntu' && matrix.config.use-clang == true && matrix.config.use-clang_stdlib ) || matrix.config.os == 'macos' ) && 'enabled' || 'disabled' }} -Dbuild_installer=true
34+
run: meson setup build -Dbuildtype=release -Ddefault_library=shared -Dbuild_installer=true
4835

4936
- name: Build
5037
run: meson compile -C build
@@ -65,7 +52,6 @@ jobs:
6552
6653
- name: Upload artifacts - Windows
6754
uses: actions/upload-artifact@v4
68-
if: matrix.config.os == 'windows'
6955
with:
70-
name: ${{ matrix.config.name }}
56+
name: OOpetris Setup
7157
path: tools/installer/OOPetris Setup.exe

0 commit comments

Comments
 (0)