mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-14 17:43:53 +00:00
178 lines
6.8 KiB
Diff
178 lines
6.8 KiB
Diff
--- ci.yml 2021-09-23 08:56:16.435724635 -0700
|
|
+++ ci_sh_def.yml 2021-09-23 08:58:17.525809197 -0700
|
|
@@ -1,4 +1,16 @@
|
|
-name: CI-SH-AVL
|
|
+# PLEASE KEEP THIS GROUP OF FILES IN SYNC AT ALL TIMES:
|
|
+# ci.yml
|
|
+# ci_sh_def.yml
|
|
+# ci_sh_def.yml.patch
|
|
+# To import changes made to ci.yml *** ESPECIALLY AFTER `git merge master` ***:
|
|
+# patch -i ci_sh_def.yml.patch -o ci_sh_def.yml
|
|
+# To update the patch file after making changes to ci_sh.yml:
|
|
+# diff -u ci.yml ci_sh_def.yml > ci_sh_def.yml.patch
|
|
+# git commit -a -m 'Tracking ci.yml changes from master.'
|
|
+#
|
|
+# Thanks a lot to @rhaschke for PR #2930!
|
|
+
|
|
+name: "CI-SH-DEF"
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
@@ -104,6 +116,7 @@
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
-DCMAKE_CXX_STANDARD=11
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT ${{runner.os == 'Windows' && '/GR /EHsc' || ''}}"
|
|
${{ matrix.args }}
|
|
|
|
- name: Build C++11
|
|
@@ -131,6 +144,7 @@
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
-DCMAKE_CXX_STANDARD=17
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT ${{runner.os == 'Windows' && '/GR /EHsc' || ''}}"
|
|
${{ matrix.args }}
|
|
${{ matrix.args2 }}
|
|
|
|
@@ -153,6 +167,7 @@
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
-DCMAKE_CXX_STANDARD=17
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT ${{runner.os == 'Windows' && '/GR /EHsc' || ''}}"
|
|
-DPYBIND11_INTERNALS_VERSION=10000000
|
|
"-DPYBIND11_TEST_OVERRIDE=test_call_policies.cpp;test_gil_scoped.cpp;test_thread.cpp"
|
|
${{ matrix.args }}
|
|
@@ -251,6 +266,7 @@
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
-DCMAKE_CXX_STANDARD=17
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
|
|
- name: Build
|
|
run: cmake --build build -j 2
|
|
@@ -305,6 +321,7 @@
|
|
-DPYBIND11_WERROR=ON
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DCMAKE_CXX_STANDARD=${{ matrix.std }}
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
|
|
|
|
- name: Build
|
|
@@ -334,7 +351,8 @@
|
|
run: apt-get update && DEBIAN_FRONTEND="noninteractive" apt-get install -y cmake git python3-dev python3-pytest python3-numpy
|
|
|
|
- name: Configure
|
|
- run: cmake -S . -B build -DPYBIND11_CUDA_TESTS=ON -DPYBIND11_WERROR=ON -DDOWNLOAD_CATCH=ON
|
|
+ run: cmake -S . -B build -DPYBIND11_CUDA_TESTS=ON -DPYBIND11_WERROR=ON -DDOWNLOAD_CATCH=ON -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
+
|
|
|
|
- name: Build
|
|
run: cmake --build build -j2 --verbose
|
|
@@ -414,7 +432,7 @@
|
|
cmake3 -S . -B build -DDOWNLOAD_CATCH=ON \
|
|
-DCMAKE_CXX_STANDARD=11 \
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)") \
|
|
- -DCMAKE_CXX_FLAGS="-Wc,--pending_instantiations=0" \
|
|
+ -DCMAKE_CXX_FLAGS="-Wc,--pending_instantiations=0 -DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" \
|
|
-DPYBIND11_TEST_FILTER="test_smart_ptr.cpp;test_virtual_functions.cpp"
|
|
|
|
# Building before installing Pip should produce a warning but not an error
|
|
@@ -473,6 +491,7 @@
|
|
-DPYBIND11_WERROR=ON
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DCMAKE_CXX_STANDARD=${{ matrix.std }}
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
|
|
|
|
- name: Build
|
|
@@ -528,6 +547,7 @@
|
|
-DDOWNLOAD_CATCH=ON \
|
|
-DDOWNLOAD_EIGEN=OFF \
|
|
-DCMAKE_CXX_STANDARD=11 \
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" \
|
|
-DCMAKE_CXX_COMPILER=$(which icpc) \
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
|
|
|
|
@@ -560,6 +580,7 @@
|
|
-DDOWNLOAD_CATCH=ON \
|
|
-DDOWNLOAD_EIGEN=OFF \
|
|
-DCMAKE_CXX_STANDARD=17 \
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" \
|
|
-DCMAKE_CXX_COMPILER=$(which icpc) \
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
|
|
|
|
@@ -630,6 +651,7 @@
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
-DCMAKE_CXX_STANDARD=11
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
|
|
|
|
- name: Build
|
|
@@ -680,6 +702,7 @@
|
|
cmake ../pybind11-tests
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DPYBIND11_WERROR=ON
|
|
+ -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
|
|
working-directory: /build-tests
|
|
|
|
@@ -775,6 +798,7 @@
|
|
-DPYBIND11_WERROR=ON
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
+ -DCMAKE_CXX_FLAGS="/GR /EHsc /DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
${{ matrix.args }}
|
|
- name: Build C++11
|
|
run: cmake --build build -j 2
|
|
@@ -821,6 +845,7 @@
|
|
-DPYBIND11_WERROR=ON
|
|
-DDOWNLOAD_CATCH=ON
|
|
-DDOWNLOAD_EIGEN=ON
|
|
+ -DCMAKE_CXX_FLAGS="/GR /EHsc /DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
|
|
- name: Build C++14
|
|
run: cmake --build build -j 2
|
|
@@ -841,12 +866,13 @@
|
|
- 3.7
|
|
std:
|
|
- 14
|
|
+ args: [ -DCMAKE_CXX_FLAGS="/GR /EHsc /DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" ]
|
|
|
|
include:
|
|
- python: 2.7
|
|
std: 17
|
|
args: >
|
|
- -DCMAKE_CXX_FLAGS="/permissive- /EHsc /GR"
|
|
+ -DCMAKE_CXX_FLAGS="/permissive- /EHsc /GR /DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT"
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
@@ -913,7 +939,7 @@
|
|
- name: Configure C++11
|
|
# LTO leads to many undefined reference like
|
|
# `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 -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" -S . -B build
|
|
|
|
- name: Build C++11
|
|
run: cmake --build build -j 2
|
|
@@ -931,7 +957,7 @@
|
|
run: git clean -fdx
|
|
|
|
- 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 -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" -S . -B build2
|
|
|
|
- name: Build C++14
|
|
run: cmake --build build2 -j 2
|
|
@@ -949,7 +975,7 @@
|
|
run: git clean -fdx
|
|
|
|
- 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 -DCMAKE_CXX_FLAGS="-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT" -S . -B build3
|
|
|
|
- name: Build C++17
|
|
run: cmake --build build3 -j 2
|