Skip to content
This repository was archived by the owner on Jan 29, 2026. It is now read-only.

Conversation

@mochaaP
Copy link
Contributor

@mochaaP mochaaP commented Dec 1, 2025

CMake feature parity:

  • Export meson target
  • Export meson c++20 modules target
  • Export cmake target
  • Installing headers
  • Googletest support
  • Freestanding tests
  • Modules tests
  • Google Benchmark support
  • Extract examples from docs

Extra features:

  • Export pkgconfig target
  • clang-format support
  • Make fmtlib optional when building examples
  • Install documents to docdir

Tested on Fedora Linux 44 (gcc/clang/msvc-wine + ninja) and Windows 10 22H2 (msvc + vs2022).

@mochaaP
Copy link
Contributor Author

mochaaP commented Dec 1, 2025

@microsoft-github-policy-service agree

@mochaaP mochaaP force-pushed the mochaa branch 8 times, most recently from 911dd00 to 3f00088 Compare December 1, 2025 17:33
@mochaaP mochaaP force-pushed the mochaa branch 6 times, most recently from fcf4cdf to 94cae03 Compare December 2, 2025 03:02
Copy link
Contributor

@mingxwa mingxwa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the contribution! Adding Meson support is a great addition to make the library more accessible. However, I have some concerns regarding the maintenance of the build files and the CI configuration.

@mochaaP
Copy link
Contributor Author

mochaaP commented Dec 2, 2025

Thank you for the extensive review. I will work on the changes later.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds comprehensive Meson build system support to the project alongside the existing CMake setup. The implementation includes building the library, tests, benchmarks, and extracting examples from documentation, with support for C++20 modules and various compiler configurations.

Key changes:

  • Complete Meson build configuration with feature parity to CMake (modules, tests, benchmarks, examples)
  • Python automation scripts for test/benchmark discovery and documentation example extraction
  • GitHub Actions CI workflow for testing Meson builds across multiple platforms and compilers

Reviewed changes

Copilot reviewed 22 out of 23 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
meson.build Main build configuration defining project metadata, compiler checks, dependencies, and library targets
meson.options Build options for enabling/disabling tests, benchmarks, examples, modules, and freestanding support
meson.format Code formatting configuration for Meson files
tools/meson_extract_doctest.py Script to extract C++ code examples from markdown documentation
tools/meson_autogen_tests.py Script to auto-generate test case lists from GTest JSON output
tools/meson_autogen_doctest.py Script to auto-generate documentation example file lists
tools/meson_autogen_benchmarks.py Script to auto-generate benchmark suite definitions
tools/meson.build Build configuration to locate Python automation scripts
tools/extract_example_code_from_docs.py Refactored script with type hints and improved structure for extracting code examples
tests/meson.build Test suite configuration including standard, freestanding, and module tests
tests/modules/meson.build C++20 modules-specific test configuration
benchmarks/meson.build Benchmark suite configuration
docs/meson.build Configuration for building and testing documentation examples
docs/example.cpp.in Template file for generated example code
subprojects/*.wrap Meson wrap files for external dependencies (googletest, google-benchmark, fmt)
tests/proxy_reflection_tests.cpp Fixed test using more accurate type trait combination
include/proxy/v4/proxy_fmt.h Added fmt v12+ compatibility check for wchar_t support
.github/workflows/meson.yml CI workflow for testing Meson builds with various compilers and configurations
.github/workflows/pipeline-ci.yml Updated main CI pipeline to include Meson workflow
.github/workflows/pipeline-release.yml Fixed tar command argument ordering in release script
.gitignore Added Meson build artifacts and Python cache to ignore list

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mochaaP mochaaP force-pushed the mochaa branch 2 times, most recently from ee03832 to 201a753 Compare December 6, 2025 12:15
@mochaaP mochaaP requested a review from mingxwa December 6, 2025 15:15
@mochaaP mochaaP force-pushed the mochaa branch 2 times, most recently from 984e89e to c02d4db Compare December 6, 2025 17:06
With specialization for libc++. Fixes compilation on libc++ 16-18 that
has incomplete std::format support.
mingxwa
mingxwa previously requested changes Dec 7, 2025
@mingxwa mingxwa dismissed their stale review January 28, 2026 08:09

Module issues can be resolved in a separate PR

@mingxwa mingxwa merged commit a560297 into microsoft:main Jan 28, 2026
16 checks passed
@mochaaP
Copy link
Contributor Author

mochaaP commented Jan 28, 2026

Modules support is soon OOTB on meson, I'm working on it upstream

edit:
Soon™
need more time cooking to make it good and correct.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants