Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions .claude/skills/sqlitecpp-build-cmake/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,5 @@ description: Build SQLiteCpp with CMake. Use for CMake builds, tests, options, o
- If the submodule is needed: `git submodule update --init --recursive`.
- SQLiteCpp requires CMake 3.16 or newer and C++17 or newer.
- Keep the minimum CMake version deliberate and update CMake configuration and documentation together.
- The `...4.0` policy maximum in `cmake_minimum_required` does not cap the supported CMake version;
it opts into policy behavior through CMake 4.0 while still allowing newer CMake releases.
- The `...4.4` policy maximum in `cmake_minimum_required` does not cap the supported CMake version;
it opts into policy behavior through CMake 4.4 while still allowing newer CMake releases.
73 changes: 73 additions & 0 deletions .github/workflows/cmake_policy_4_4.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: Latest CMake / 4.4 policies

on: [push, pull_request]

jobs:
build:
name: ${{ matrix.os }}
runs-on: ${{ matrix.os }}

strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
- macos-latest

steps:
- uses: actions/checkout@v4
with:
submodules: recursive

- uses: actions/setup-python@v6
with:
python-version: "3.x"

- name: Install latest CMake
run: python -m pip install --upgrade cmake

- name: Check CMake version
run: cmake --version

- name: Configure SQLiteCpp
run: >
cmake
-S .
-B build/main
-DCMAKE_BUILD_TYPE=Debug
-DSQLITECPP_BUILD_TESTS=ON
-DSQLITECPP_BUILD_EXAMPLES=ON
-DSQLITECPP_RUN_CPPCHECK=OFF
-DSQLITECPP_RUN_CPPLINT=OFF

- name: Build SQLiteCpp
run: cmake --build build/main --config Debug

- name: Test SQLiteCpp
run: ctest --test-dir build/main --build-config Debug --output-on-failure

- name: Configure C++20 consumer
run: >
cmake
-S tests/consumer
-B build/consumer
-DCMAKE_BUILD_TYPE=Debug
-DSQLITECPP_CXX_STANDARD=17
-DCONSUMER_CXX_STANDARD=20

- name: Build consumer
run: cmake --build build/consumer --config Debug

- name: Test consumer
run: ctest --test-dir build/consumer --build-config Debug --output-on-failure

- name: Configure subdirectory example
run: >
cmake
-S examples/example2
-B build/example2
-DCMAKE_BUILD_TYPE=Debug

- name: Build subdirectory example
run: cmake --build build/example2 --config Debug
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- Require CMake 3.16 or newer
- Require C++17 and test C++20 compatibility
- Adopt CMake 4.4 policies

## [3.4.0] - 2026-09-21

Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# Distributed under the MIT License (MIT) (See accompanying file LICENSE.txt
# or copy at http://opensource.org/licenses/MIT)
cmake_minimum_required(VERSION 3.16...4.0)
cmake_minimum_required(VERSION 3.16...4.4)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") # custom CMake modules like FindSQLiteCpp
project(SQLiteCpp VERSION 4.0.0)

Expand Down
2 changes: 1 addition & 1 deletion examples/example2/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# Distributed under the MIT License (MIT) (See accompanying file LICENSE.txt
# or copy at http://opensource.org/licenses/MIT)
cmake_minimum_required(VERSION 3.16...4.0)
cmake_minimum_required(VERSION 3.16...4.4)
project(SQLiteCpp_Example VERSION 2.0)

# SQLiteCpp requires a C++17 compiler
Expand Down
2 changes: 1 addition & 1 deletion tests/consumer/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.16...4.0)
cmake_minimum_required(VERSION 3.16...4.4)
project(SQLiteCpp_Consumer LANGUAGES CXX)

set(SQLITECPP_CXX_STANDARD 17 CACHE STRING "C++ standard used to build SQLiteCpp")
Expand Down
Loading