]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-141563: Fix test_cppext on macOS (#144685)
authorVictor Stinner <vstinner@python.org>
Tue, 10 Feb 2026 19:31:12 +0000 (20:31 +0100)
committerGitHub <noreply@github.com>
Tue, 10 Feb 2026 19:31:12 +0000 (20:31 +0100)
commitb67a64d7e277b6ab7b4d77e12f35c58b64f55e65
treea69f58f2b60e24b38b48d48b85fe2214ff90b449
parenteb6d0e0b2b9f1cc36fb2b7e396bf3100214b3e09
gh-141563: Fix test_cppext on macOS (#144685)

Don't test internal header files including mimalloc on macOS since
mimalloc emits compiler warnings:

  In file included from extension.cpp:21:
  In file included from Include/internal/pycore_backoff.h:15:
  In file included from Include/internal/pycore_interp_structs.h:15:
  In file included from Include/internal/pycore_tstate.h:14:
  In file included from Include/internal/pycore_mimalloc.h:43:
  Include/internal/mimalloc/mimalloc.h:464:85: error: defaulted
  function definitions are a C++11 extension
  [-Werror,-Wc++11-extensions]
    mi_stl_allocator() mi_attr_noexcept = default;
                                                                                      ^
  Include/internal/mimalloc/mimalloc.h:465:85: error: defaulted
  function definitions are a C++11 extension
  [-Werror,-Wc++11-extensions]
    mi_stl_allocator(const mi_stl_allocator&) mi_attr_noexcept = default;

Log also CXX and CXXFLAGS env vars in test_cppext. Log also CPPFLAGS
in test_cext.
Lib/test/test_cext/setup.py
Lib/test/test_cppext/extension.cpp
Lib/test/test_cppext/setup.py