summaryrefslogtreecommitdiff
path: root/sys-cluster/ceph/files/ceph-19.2.1-mgr.patch
blob: 91569105a616483a2ee556e267ff141c9580b9e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
From d44b2227cdc6d1e2ad4b242473f6c392419d6fbf Mon Sep 17 00:00:00 2001
From: Adam Emerson <aemerson@redhat.com>
Date: Mon, 6 Jan 2025 21:01:49 -0500
Subject: [PATCH] mgr: Work around bug in Boost MPI/Python

Thanks to the maintainers of the Arch User Repository Ceph PKGBUILD
for this fix.

Signed-off-by: Adam Emerson <aemerson@redhat.com>
---
 src/mgr/PyModule.cc | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/src/mgr/PyModule.cc b/src/mgr/PyModule.cc
index cff63ef4a6b68..4f996489ba082 100644
--- a/src/mgr/PyModule.cc
+++ b/src/mgr/PyModule.cc
@@ -38,6 +38,18 @@ std::string PyModule::mgr_store_prefix = "mgr/";
 #define BOOST_BIND_GLOBAL_PLACEHOLDERS
 // Boost apparently can't be bothered to fix its own usage of its own
 // deprecated features.
+
+// Fix instances of "'BOOST_PP_ITERATION_02' was not declared in this scope; did
+// you mean 'BOOST_PP_ITERATION_05'" and related macro error bullshit that spans
+// 300 lines of errors
+//
+// Apparently you can't include boost/python stuff _and_ have this header
+// defined
+//
+// Thanks to the ceph-aur folks for the fix at:
+// https://github.com/bazaah/aur-ceph/commit/8c5cc7d8deec002f7596b6d0860859a0a718f12b 
+#undef BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
+
 #include <boost/python/extract.hpp>
 #include <boost/python/import.hpp>
 #include <boost/python/object.hpp>