[gcc r13-9185] libstdc++: Suppress deprecation messages from <tbb/task.h> [PR101228]
Jonathan Wakely
redi@gcc.gnu.org
Wed Nov 13 21:21:38 GMT 2024
https://gcc.gnu.org/g:3e2b297b0bb77317e759a180a5d4b701f6e5e6e4
commit r13-9185-g3e2b297b0bb77317e759a180a5d4b701f6e5e6e4
Author: Jonathan Wakely <jwakely@redhat.com>
Date: Thu Feb 29 17:13:49 2024 +0000
libstdc++: Suppress deprecation messages from <tbb/task.h> [PR101228]
libstdc++-v3/ChangeLog:
PR libstdc++/101228
* include/pstl/parallel_backend_tbb.h (TBB_SUPPRESS_DEPRECATED_MESSAGES):
Define before including <tbb/task.h> then undef afterwards.
(cherry picked from commit c608b57f77a47179899666940c3b8b6a2e5435b2)
Diff:
---
libstdc++-v3/include/pstl/parallel_backend_tbb.h | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/libstdc++-v3/include/pstl/parallel_backend_tbb.h b/libstdc++-v3/include/pstl/parallel_backend_tbb.h
index 3fd1a06ebd89..413c7843bb8b 100644
--- a/libstdc++-v3/include/pstl/parallel_backend_tbb.h
+++ b/libstdc++-v3/include/pstl/parallel_backend_tbb.h
@@ -15,6 +15,11 @@
#include "parallel_backend_utils.h"
+#ifndef TBB_SUPPRESS_DEPRECATED_MESSAGES
+# define TBB_SUPPRESS_DEPRECATED_MESSAGES 1
+# define _GLIBCXX_UNDEF_SUPPRESS
+#endif
+
// Bring in minimal required subset of Intel TBB
#include <tbb/blocked_range.h>
#include <tbb/parallel_for.h>
@@ -25,6 +30,11 @@
#include <tbb/tbb_allocator.h>
#include <tbb/task.h>
+#ifdef _GLIBCXX_UNDEF_SUPPRESS
+# undef TBB_SUPPRESS_DEPRECATED_MESSAGES
+# undef _GLIBCXX_UNDEF_SUPPRESS
+#endif
+
#if TBB_INTERFACE_VERSION < 10000
# error Intel(R) Threading Building Blocks 2018 is required; older versions are not supported.
#endif
More information about the Libstdc++-cvs
mailing list