Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
459fbdc
Add Windows CI build too
ClausKlein Jan 10, 2026
f3c5c4a
Use portable C++20 check
ClausKlein Jan 10, 2026
9ad29b7
Use C++23 on Windows
ClausKlein Jan 10, 2026
01a4dcf
Quickfix to compile with C++23
ClausKlein Jan 10, 2026
6f75603
Add simple BEMAN_SCOPE_USE_FALLBACK code
ClausKlein Jan 11, 2026
d83e3f4
Fix Windows CI test directory
ClausKlein Jan 11, 2026
2f5ab94
Refactory unique_resource code to be portable
ClausKlein Jan 13, 2026
4a9894d
Prevent use of explicit operator bool() const noexcept
ClausKlein Jan 13, 2026
7d92b09
Test appleclang on CI too
ClausKlein Jan 14, 2026
58335ff
Deleted move assignment operators
ClausKlein Jan 15, 2026
1a86a99
Try to BUILD_SHARED_LIBS on windows
ClausKlein Jan 15, 2026
8c63627
Use GenerateExportHeader cmake module
ClausKlein Jan 15, 2026
f51bfa4
Quickfix for missing export header
ClausKlein Jan 16, 2026
c9197e6
Use ctest --build-and-test to check the installed version
ClausKlein Jan 17, 2026
7af734d
The final cut
ClausKlein Jan 17, 2026
3c99179
Prevent use of std::print() for now
ClausKlein Jan 17, 2026
9b63207
Add infra submodule and use it
ClausKlein Jan 27, 2026
38f5da3
infra/tools/beman-submodule/beman-submodule update
ClausKlein Jan 27, 2026
3d810f1
Refactory CXX_MODULE according to Daniela advice
ClausKlein Feb 27, 2026
4a35cc4
Next steps with import std;
ClausKlein Mar 3, 2026
5c6aa81
Try to prevent linker problems on OSX with gcc-15
ClausKlein Mar 3, 2026
cfca6f4
Use beman_install_library() cmake function
ClausKlein Mar 25, 2026
a3e4d2e
Merge branch 'main' into feature/add-windows-ci
ClausKlein Mar 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ IndentCaseBlocks: false
IndentCaseLabels: false
IndentExternBlock: AfterExternBlock
IndentGotoLabels: true
IndentPPDirectives: None
IndentPPDirectives: BeforeHash
IndentRequiresClause: true
IndentWidth: 4
IndentWrappedFunctionNames: false
Expand Down
65 changes: 44 additions & 21 deletions .github/workflows/ci_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,25 +10,28 @@ on:
workflow_dispatch:
schedule:
- cron: '30 15 * * *'
- cron: "0 0 * * 0"

jobs:
beman-submodule-check:
uses: ./.github/workflows/reusable-beman-submodule-check.yml
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-submodule-check.yml@1.3.0

preset-test:
uses: ./.github/workflows/reusable-beman-preset-test.yml
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-preset-test.yml@1.3.0
with:
matrix_config: >
[
{"preset": "gcc-debug", "image": "ghcr.io/bemanproject/infra-containers-gcc:latest"},
{"preset": "gcc-release", "image": "ghcr.io/bemanproject/infra-containers-gcc:latest"},
{"preset": "llvm-debug", "image": "ghcr.io/bemanproject/infra-containers-clang:latest"},
{"preset": "llvm-release", "image": "ghcr.io/bemanproject/infra-containers-clang:latest"},
{"preset": "appleclang-debug", "runner": "macos-latest"},
{"preset": "appleclang-release", "runner": "macos-latest"},
{"preset": "msvc-debug", "runner": "windows-latest"},
{"preset": "msvc-release", "runner": "windows-latest"}
]

build-and-test:
uses: ./.github/workflows/reusable-beman-build-and-test.yml
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-build-and-test.yml@1.3.0
with:
matrix_config: >
{
Expand All @@ -39,9 +42,9 @@ jobs:
"tests": [
{ "stdlibs": ["libstdc++"],
"tests": [
"Debug.Default", "Release.Default", "Release.TSan",
"Release.MaxSan", "Debug.Werror", "Debug.Dynamic",
"Debug.Coverage"
"Debug.Default", "Release.Default", "Release.MaxSan",
"Debug.Coverage", "Debug.Werror",
"Debug.Dynamic", "Release.Dynamic"
]
}
]
Expand All @@ -51,7 +54,7 @@ jobs:
}
]
},
{ "versions": ["14", "13"],
{ "versions": ["14"],
"tests": [
{ "cxxversions": ["c++26", "c++23", "c++20"],
"tests": [{ "stdlibs": ["libstdc++"], "tests": ["Release.Default"]}]
Expand All @@ -60,30 +63,54 @@ jobs:
}
],
"clang": [
{ "versions": ["20"],
{ "versions": ["21"],
"tests": [
{"cxxversions": ["c++26"],
"tests": [
{ "stdlibs": ["libstdc++"],
{ "stdlibs": ["libc++"],
"tests": [
"Debug.Default", "Release.Default", "Release.TSan",
"Release.MaxSan", "Debug.Werror", "Debug.Dynamic"
"Debug.Default", "Release.Default", "Release.MaxSan",
"Debug.Dynamic", "Release.Dynamic"
]
}
]
},
{ "cxxversions": ["c++23", "c++20"],
"tests": [
{"stdlibs": ["libstdc++"], "tests": ["Release.Default"]}
{"stdlibs": ["libc++"], "tests": ["Release.Default"]}
]
}
]
},
{ "versions": ["19"],
{ "versions": ["20", "19"],
"tests": [
{ "cxxversions": ["c++26", "c++23", "c++20"],
"tests": [
{"stdlibs": ["libstdc++"], "tests": ["Release.Default"]}
{"stdlibs": ["libc++"], "tests": ["Release.Default"]}
]
}
]
}
],
"appleclang": [
{ "versions": ["latest"],
"tests": [
{ "cxxversions": ["c++23", "c++20"],
"tests": [{ "stdlibs": ["libc++"], "tests": ["Release.Default"]}]
}
]
}
],
"msvc": [
{ "versions": ["latest"],
"tests": [
{ "cxxversions": ["c++23"],
"tests": [
{ "stdlibs": ["stl"],
"tests": ["Debug.Default", "Release.Default", "Release.MaxSan",
"Debug.Dynamic", "Release.Dynamic"
]
}
]
}
]
Expand All @@ -93,9 +120,5 @@ jobs:

create-issue-when-fault:
needs: [preset-test, build-and-test]
if: failure() && github.event.schedule == '30 15 * * *'
uses: ./.github/workflows/reusable-beman-create-issue-when-fault.yml

auto-update-pre-commit:
if: github.event.schedule == '00 16 * * 0'
uses: ./.github/workflows/reusable-beman-update-pre-commit.yml
if: failure() && github.event_name == 'schedule'
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-create-issue-when-fault.yml@1.3.0
79 changes: 79 additions & 0 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
---
name: CMake

on:
push:
branches: ["develop"]
pull_request:
branches: ["develop"]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
schedule:
# run at 15:30 on day-of-month 7.
- cron: '30 15 7 * *'

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: release
CTEST_OUTPUT_ON_FAILURE: 1

jobs:
build:
strategy:
fail-fast: false

matrix:
os: [windows]
include:
- { os: macos, uname: appleclang }
# XXX - { os: ubuntu, uname: gcc }
- { os: ubuntu, uname: llvm }
- { os: windows, uname: msvc }

# TODO(CK):
# type: [shared, static]
# include:
# - { type: shared, shared: YES }
# - { type: static, shared: NO }

runs-on: ${{ matrix.os }}-latest

steps:
- uses: actions/checkout@v4
- name: Setup build environment
uses: lukka/get-cmake@latest
with:
cmakeVersion: "~4.2.1"
ninjaVersion: "^1.13.0"

- name: Setup MSVC
if: startsWith(matrix.os, 'windows')
uses: TheMrMilchmann/setup-msvc-dev@v3
with:
arch: x64

- name: Setup Cpp
if: matrix.os != 'windows'
uses: aminya/setup-cpp@v1
with:
# XXX compiler: ${{matrix.uname}}
compiler: llvm

- name: Configure CMake
run: cmake --preset ${{matrix.uname}}-${{env.BUILD_TYPE}} --log-level=VERBOSE # XXX -Wdev

- name: Build
# Build your program with the given configuration
run: cmake --build --preset ${{matrix.uname}}-${{env.BUILD_TYPE}}

- name: Test
# Execute tests defined by the CMake configuration
run: ctest --preset ${{matrix.uname}}-${{env.BUILD_TYPE}}

# - name: Install
# # Install the project artefacts to CMAKE_INSTALL_PREFIX
# run: cmake --build --preset ${{matrix.uname}}-${{env.BUILD_TYPE}} --target install
13 changes: 13 additions & 0 deletions .github/workflows/pre-commit-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Lint Check (pre-commit)

on:
# We have to use pull_request_target here as pull_request does not grant
# enough permission for reviewdog
pull_request_target:
push:
branches:
- main

jobs:
pre-commit:
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-pre-commit.yml@1.3.0
15 changes: 15 additions & 0 deletions .github/workflows/pre-commit-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

name: Weekly pre-commit autoupdate

on:
workflow_dispatch:
schedule:
- cron: "0 16 * * 0"

jobs:
auto-update-pre-commit:
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-update-pre-commit.yml@1.3.0
secrets:
APP_ID: ${{ secrets.AUTO_PR_BOT_APP_ID }}
PRIVATE_KEY: ${{ secrets.AUTO_PR_BOT_PRIVATE_KEY }}
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
.cache
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

/compile_commands.json
/CMakeUserPresets.json
/build
**/_deps/
**/CMakeFiles/
/cmake/presets

# ignore emacs temp files
*~
\#*\#

# ignore vscode settings
.vscode
.cache
30 changes: 15 additions & 15 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,39 +4,39 @@ repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
exclude: ^\.clang-(format|tidy)$
- id: check-added-large-files
- id: check-added-large-files

# Clang-format for C++
# This brings in a portable version of clang-format.
# See also: https://github.com/ssciwr/clang-format-wheel
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v21.1.6
rev: v22.1.1
hooks:
- id: clang-format
types_or: [c++, c, json]
- id: clang-format
types_or: [c++, c, json]

# CMake linting and formatting
- repo: https://github.com/BlankSpruce/gersemi
rev: 0.23.1
rev: 0.26.1
hooks:
- id: gersemi
name: CMake linting
exclude: ^.*/tests/.*/data/ # Exclude test data directories
- id: gersemi
name: CMake linting
exclude: ^.*/tests/.*/data/ # Exclude test data directories

# Markdown linting
# Config file: .markdownlint.yaml
# Commented out to disable this by default. Uncomment to enable markdown linting.
# Commented out to disable this by default. Uncomment to enable markdown linting.
# - repo: https://github.com/igorshubovych/markdownlint-cli
# rev: v0.46.0
# rev: v0.47.0
# hooks:
# - id: markdownlint
# - id: markdownlint

- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
rev: v2.4.2
hooks:
- id: codespell
args: ["--ignore-words-list=wil"]
Expand Down
Loading
Loading