Merge branch 'pybind:master' into master

This commit is contained in:
Steve R. Sun 2022-02-07 11:10:11 +08:00 committed by GitHub
commit de3b26f8e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 4 deletions

View File

@ -914,7 +914,7 @@ jobs:
- name: Configure C++11 - name: Configure C++11
# LTO leads to many undefined reference like # LTO leads to many undefined reference like
# `pybind11::detail::function_call::function_call(pybind11::detail::function_call&&) # `pybind11::detail::function_call::function_call(pybind11::detail::function_call&&)
run: cmake -G "MinGW Makefiles" -DCMAKE_CXX_STANDARD=11 -S . -B build run: cmake -G "MinGW Makefiles" -DCMAKE_CXX_STANDARD=11 -DDOWNLOAD_CATCH=ON -S . -B build
- name: Build C++11 - name: Build C++11
run: cmake --build build -j 2 run: cmake --build build -j 2
@ -932,7 +932,7 @@ jobs:
run: git clean -fdx run: git clean -fdx
- name: Configure C++14 - name: Configure C++14
run: cmake -G "MinGW Makefiles" -DCMAKE_CXX_STANDARD=14 -S . -B build2 run: cmake -G "MinGW Makefiles" -DCMAKE_CXX_STANDARD=14 -DDOWNLOAD_CATCH=ON -S . -B build2
- name: Build C++14 - name: Build C++14
run: cmake --build build2 -j 2 run: cmake --build build2 -j 2
@ -950,7 +950,7 @@ jobs:
run: git clean -fdx run: git clean -fdx
- name: Configure C++17 - name: Configure C++17
run: cmake -G "MinGW Makefiles" -DCMAKE_CXX_STANDARD=17 -S . -B build3 run: cmake -G "MinGW Makefiles" -DCMAKE_CXX_STANDARD=17 -DDOWNLOAD_CATCH=ON -S . -B build3
- name: Build C++17 - name: Build C++17
run: cmake --build build3 -j 2 run: cmake --build build3 -j 2

View File

@ -7,7 +7,7 @@ if("${PYTHON_MODULE_EXTENSION}" MATCHES "pypy" OR "${Python_INTERPRETER_ID}" STR
return() return()
endif() endif()
find_package(Catch 2.13.2) find_package(Catch 2.13.5)
if(CATCH_FOUND) if(CATCH_FOUND)
message(STATUS "Building interpreter tests using Catch v${CATCH_VERSION}") message(STATUS "Building interpreter tests using Catch v${CATCH_VERSION}")

View File

@ -9,6 +9,11 @@
# pragma warning(disable: 4996) # pragma warning(disable: 4996)
#endif #endif
// Catch uses _ internally, which breaks gettext style defines
#ifdef _
#undef _
#endif
#define CATCH_CONFIG_RUNNER #define CATCH_CONFIG_RUNNER
#include <catch.hpp> #include <catch.hpp>