Skip to content

reduce warning level #20

reduce warning level

reduce warning level #20

Workflow file for this run

# SPDX-FileCopyrightText: 2022 - 2023 Peter Urban, Ghent University
#
# SPDX-License-Identifier: CC0-1.0
name: win
on:
push:
branches: [ main ]
paths-ignore:
- '.github/workflows/python-package*'
- '.github/workflows/cibuildwheels*'
- '.github/workflows/conda*'
- '.github/workflows/test_*'
- '.github/workflows/ci-linux*'
- '.github/workflows/ci-mac*'
- 'conda.recipe/*'
- '*.md'
- 'doc/*'
#paths:
# - "**meson.build"
# - "**.cpp"
# - "**.c"
# - "**.h"
pull_request:
branches: [ main ]
paths-ignore:
- '.github/workflows/python-package*'
- '.github/workflows/cibuildwheels*'
- '.github/workflows/conda*'
- '.github/workflows/test_*'
- '.github/workflows/ci-linux*'
- '.github/workflows/ci-mac*'
- 'conda.recipe/*'
- '*.md'
- 'doc/*'
#paths:
# - "**meson.build"
# - "**.cpp"
# - "**.c"
# - "**.h"
# make sure that multiple jobs don't run for the same action (new commits cancel old jobs when they are still running)
# Souce Ralf Gommers (commit to meson-python)
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
# env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
#BUILD_TYPE: Release
jobs:
build-on-windows:
name: ${{matrix.os}}
runs-on: ${{matrix.os}}
strategy:
fail-fast: false
matrix:
os: [windows-2019, windows-2022]
boost-version: [1.84.0]
boost-version_: [1_84_0]
boost-modules: [--with-iostreams]
include:
- toolset: vc143
compiler: clang-cl
cpp_std: c++20
# - toolset: msvc
# compiler: sccache cl
# cpp_std: c++20
env:
#CC: msvc-14.32
CC: ${{matrix.compiler}}
CXX: ${{matrix.compiler}}
#this is where we will download ninja later
NINJA: d:/ninja.exe
#container: python:latest #pull directly from dockerhub
steps:
- name: setup python
uses: actions/setup-python@v3
with:
python-version: '3.12'
# make sure meson can find msvc
- uses: TheMrMilchmann/setup-msvc-dev@v2
with:
arch: x64
#toolset: 14.34
- name: checkout main repository
uses: actions/checkout@v4
with:
submodules: recursive
lfs: false
- name: sccache
uses: hendrikmuhs/[email protected]
with:
key: super-ci-win # name for the cache
variant: sccache # supports windows
- name: Cache Boost
id: cache-boost
uses: actions/cache@v3
with:
path: c:\Boost
#key: windows-msvc-14.32-boost-${{matrix.boost-version}}-${{matrix.boost-modules}}
key: windows-${{matrix.toolset}}-boost-${{matrix.boost-version}}-${{matrix.boost-modules}}
- name: Install dependencies on windows
if: steps.cache-boost.outputs.cache-hit != 'true'
run: |
Invoke-WebRequest -Uri https://boostorg.jfrog.io/artifactory/main/release/${{matrix.boost-version}}/source/boost_${{matrix.boost-version_}}.7z -outfile boost.7z
7z x boost.7z
cd .\boost_${{matrix.boost-version_}}\
.\bootstrap.bat ${{matrix.toolset}}
.\b2.exe install --variant=release --threading=multi --link=static ${{matrix.boost-modules}}
cd ..
#rm -rv boost*
- name: install dependencies (meson & python)
run: pip install meson meson-python pytest numpy
#run: pip install meson meson-python pytest numpy ninja
- name: download ninja long path
run : |
Invoke-WebRequest -Uri https://raw.githubusercontent.com/themachinethatgoesping/tools/main/ninja-windows/ninja.exe -OutFile d:\ninja.exe
- name: check ninja executable path
run: |
$env:NINJA
d:\ninja.exe --version
- name: configure meson
run: |
meson setup builddir/ -D"python.install_env=auto" -Ddefault_library=static -Dcpp_std=${{matrix.cpp_std}}
- name: compile project
run: meson compile -C builddir/
- name: test (cpp)
#run: meson test -C builddir/ --print-errorlogs
# meson test does not work with the custom ninja executable
run: ninja test -C builddir/ --verbose
- name: install project
run: meson install -C builddir/
- name: install pip requirements
run: pip install -r requirements.txt
- name: test (pytest)
run: pytest -v
- name: 'Upload error log'
uses: actions/upload-artifact@v4
if: failure()
with:
name: windows_Meson_testlog
path: builddir/meson-logs/meson-log.txt
retention-days: 5