Backport fix for buliding vtk-m diy with GCC 11 (#32465)

This commit is contained in:
kwryankrattiger 2022-09-01 13:41:20 -05:00 committed by GitHub
parent 2968ae667f
commit 117b0af831
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 27 additions and 0 deletions

View File

@ -0,0 +1,24 @@
From 671217ebdd89fa6b43bb990e0aaaf87dd57a0c5c Mon Sep 17 00:00:00 2001
From: Ryan Krattiger <ryan.krattiger@kitware.com>
Date: Wed, 31 Aug 2022 13:58:21 -0400
Subject: [PATCH] DIY: Add include of cstddef to DIY datatypes.hpp
This is required because size_t is not defined via
the STL headers included here.
---
vtkm/thirdparty/diy/vtkmdiy/include/vtkmdiy/mpi/datatypes.hpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/vtkm/thirdparty/diy/vtkmdiy/include/vtkmdiy/mpi/datatypes.hpp b/vtkm/thirdparty/diy/vtkmdiy/include/vtkmdiy/mpi/datatypes.hpp
index 24d4b3275..bec4a62d8 100644
--- a/vtkm/thirdparty/diy/vtkmdiy/include/vtkmdiy/mpi/datatypes.hpp
+++ b/vtkm/thirdparty/diy/vtkmdiy/include/vtkmdiy/mpi/datatypes.hpp
@@ -5,6 +5,7 @@
#include <vector>
#include <array>
+#include <cstddef>
namespace diy
{
--

View File

@ -130,6 +130,9 @@ class VtkM(CMakePackage, CudaPackage, ROCmPackage):
conflicts("+cuda", when="cuda_arch=none", msg="vtk-m +cuda requires that cuda_arch be set") conflicts("+cuda", when="cuda_arch=none", msg="vtk-m +cuda requires that cuda_arch be set")
# Patch
patch("diy-include-cstddef.patch", when="@1.5.3:1.8.0")
def cmake_args(self): def cmake_args(self):
spec = self.spec spec = self.spec
options = [] options = []