From 4f0502cde0bc017534b59d679db193b611cf0b83 Mon Sep 17 00:00:00 2001 From: Maarten Bent Date: Sat, 19 Nov 2022 20:00:14 +0100 Subject: [PATCH] Add clang MSW build to CI --- .github/workflows/ci_msw.yml | 34 ++++++++++++++++++++++++++++++++++ build/tools/proc_count.sh | 2 +- 2 files changed, 35 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci_msw.yml b/.github/workflows/ci_msw.yml index 52c399fbaf..b68ed19386 100644 --- a/.github/workflows/ci_msw.yml +++ b/.github/workflows/ci_msw.yml @@ -121,3 +121,37 @@ jobs: working-directory: tests run: | .\vc*msw*\test_gui.exe + + msw-msys2-clang: + runs-on: windows-latest + + defaults: + run: + shell: msys2 {0} + + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + submodules: 'recursive' + + - name: Setup MSYS2 + uses: msys2/setup-msys2@v2 + with: + msystem: mingw64 + update: true + install: mingw-w64-x86_64-cmake mingw-w64-x86_64-toolchain mingw-w64-x86_64-clang + + - name: Configuring + run: | + clang --version + cmake --version + mkdir build_cmake + pushd build_cmake + cmake -G "MinGW Makefiles" -DCMAKE_C_COMPILER=clang.exe -DCMAKE_CXX_COMPILER=clang++.exe -DwxBUILD_SAMPLES=ALL -DwxBUILD_TESTS=ALL -DwxBUILD_DEMOS=ON -DCMAKE_BUILD_TYPE=Release .. + + - name: Building + working-directory: build_cmake + run: | + wxPROC_COUNT=`../build/tools/proc_count.sh` + cmake --build . -- -j$wxPROC_COUNT diff --git a/build/tools/proc_count.sh b/build/tools/proc_count.sh index 16660df2c1..7b10dbe0ac 100755 --- a/build/tools/proc_count.sh +++ b/build/tools/proc_count.sh @@ -1,7 +1,7 @@ # This script outputs the number of available processors/cores plus one. case `uname` in - Linux) + Linux|MSYS*|MINGW*) wxPROC_COUNT=`nproc` ;;