diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2018-08-15 18:27:01 -0700 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2018-08-15 18:27:01 -0700 |
| commit | c5acdcd20f13cb484d67ac116e374060b0f2ca35 (patch) | |
| tree | 00eb2be342939d1258edad0e039a8161791d6f56 | |
| parent | 85c2fa9f0a2693018d686d4f0b6dbff583ff2140 (diff) | |
| download | vcpkg-c5acdcd20f13cb484d67ac116e374060b0f2ca35.tar.gz vcpkg-c5acdcd20f13cb484d67ac116e374060b0f2ca35.zip | |
[pybind11] Apply patch for alias templates
| -rw-r--r-- | ports/pybind11/CONTROL | 2 | ||||
| -rw-r--r-- | ports/pybind11/aliastemplates.patch | 45 | ||||
| -rw-r--r-- | ports/pybind11/portfile.cmake | 2 |
3 files changed, 48 insertions, 1 deletions
diff --git a/ports/pybind11/CONTROL b/ports/pybind11/CONTROL index c6f7f5b7e..67fdaea5d 100644 --- a/ports/pybind11/CONTROL +++ b/ports/pybind11/CONTROL @@ -1,4 +1,4 @@ Source: pybind11 -Version: 2.2.3 +Version: 2.2.3-1 Description: pybind11 is a lightweight header-only library that exposes C++ types in Python and vice versa, mainly to create Python bindings of existing C++ code. Build-Depends: python3 (windows)
\ No newline at end of file diff --git a/ports/pybind11/aliastemplates.patch b/ports/pybind11/aliastemplates.patch new file mode 100644 index 000000000..a692ad583 --- /dev/null +++ b/ports/pybind11/aliastemplates.patch @@ -0,0 +1,45 @@ +From 598ec67e4d6727dd9455bcc9959e32fee02a80ac Mon Sep 17 00:00:00 2001 +From: Michael Goulding <Michael.Goulding@microsoft.com> +Date: Wed, 18 Jul 2018 10:59:15 -0700 +Subject: [PATCH 1/2] VS 15.8.0 Preview 4.0 has a bug with alias templates + +--- + include/pybind11/detail/common.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/include/pybind11/detail/common.h b/include/pybind11/detail/common.h +index 3c6722891..89d922190 100644 +--- a/include/pybind11/detail/common.h ++++ b/include/pybind11/detail/common.h +@@ -476,7 +476,7 @@ template <typename...> struct void_t_impl { using type = void; }; + template <typename... Ts> using void_t = typename void_t_impl<Ts...>::type; + + /// Compile-time all/any/none of that check the boolean value of all template types +-#ifdef __cpp_fold_expressions ++#if (!defined(_MSC_VER) || ( _MSC_VER >= 1916 )) && defined(__cpp_fold_expressions) + template <class... Ts> using all_of = bool_constant<(Ts::value && ...)>; + template <class... Ts> using any_of = bool_constant<(Ts::value || ...)>; + #elif !defined(_MSC_VER) + +From 7d534251ca67c5e725ed549900f04adeb5ddb99e Mon Sep 17 00:00:00 2001 +From: Michael Goulding <Michael.Goulding@microsoft.com> +Date: Thu, 19 Jul 2018 10:27:41 -0700 +Subject: [PATCH 2/2] Address feedback + +--- + include/pybind11/detail/common.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/include/pybind11/detail/common.h b/include/pybind11/detail/common.h +index 89d922190..8d65b260d 100644 +--- a/include/pybind11/detail/common.h ++++ b/include/pybind11/detail/common.h +@@ -476,7 +476,7 @@ template <typename...> struct void_t_impl { using type = void; }; + template <typename... Ts> using void_t = typename void_t_impl<Ts...>::type; + + /// Compile-time all/any/none of that check the boolean value of all template types +-#if (!defined(_MSC_VER) || ( _MSC_VER >= 1916 )) && defined(__cpp_fold_expressions) ++#if defined(__cpp_fold_expressions) && !(defined(_MSC_VER) && (_MSC_VER < 1916)) + template <class... Ts> using all_of = bool_constant<(Ts::value && ...)>; + template <class... Ts> using any_of = bool_constant<(Ts::value || ...)>; + #elif !defined(_MSC_VER) diff --git a/ports/pybind11/portfile.cmake b/ports/pybind11/portfile.cmake index 892f173fa..16a9b9726 100644 --- a/ports/pybind11/portfile.cmake +++ b/ports/pybind11/portfile.cmake @@ -6,6 +6,8 @@ vcpkg_from_github( REF v2.2.3 SHA512 3a43b43f44ae4a6453fe3b875384acc868310177216938cb564536e6b73c56002743137e5f61cf4ecbd6c56e3b39476ebf06aea33d460581fc7d8ba7b2a22a67 HEAD_REF master + PATCHES + ${CMAKE_CURRENT_LIST_DIR}/aliastemplates.patch ) vcpkg_find_acquire_program(PYTHON3) |
