summaryrefslogtreecommitdiff
path: root/external
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2016-08-25 14:58:54 +0200
committerJan-Marek Glogowski <glogow@fbihome.de>2016-08-29 13:13:13 +0200
commit9dd45f9e314d6c28fdeecbe559b33615b0ed1a2d (patch)
tree17a11a08fdb9f261e56592382c85f963ff6a2979 /external
parentab67543e09568368b41faf3510841a1dd48b993f (diff)
Fixup clang Werror boost build on MacOSX
Fixes the Boost::Tuple header used by Boost::MultiIndex. Change-Id: I98eb047e699e04934ee09323633e28cecef84e70
Diffstat (limited to 'external')
-rw-r--r--external/boost/UnpackedTarball_boost.mk4
-rw-r--r--external/boost/boost.tuple_basic.Wundef.warnings.patch34
2 files changed, 38 insertions, 0 deletions
diff --git a/external/boost/UnpackedTarball_boost.mk b/external/boost/UnpackedTarball_boost.mk
index 604f882d95b0..0bdb6eb1500f 100644
--- a/external/boost/UnpackedTarball_boost.mk
+++ b/external/boost/UnpackedTarball_boost.mk
@@ -40,6 +40,10 @@ boost_patches += boost_1_60_0.quadmath.patch
boost_patches += boost_1_60_0.undef.warning.patch
boost_patches += boost_1_60_0.android.undef.warning.patch
+# This patch is from upstream
+# https://github.com/boostorg/tuple/commit/8b6613e592824b30d48a9252604172abfa33c5f2
+boost_patches += boost.tuple_basic.Wundef.warnings.patch
+
$(eval $(call gb_UnpackedTarball_UnpackedTarball,boost))
$(eval $(call gb_UnpackedTarball_set_tarball,boost,$(BOOST_TARBALL)))
diff --git a/external/boost/boost.tuple_basic.Wundef.warnings.patch b/external/boost/boost.tuple_basic.Wundef.warnings.patch
new file mode 100644
index 000000000000..778f4cc0645b
--- /dev/null
+++ b/external/boost/boost.tuple_basic.Wundef.warnings.patch
@@ -0,0 +1,34 @@
+From 8b6613e592824b30d48a9252604172abfa33c5f2 Mon Sep 17 00:00:00 2001
+From: Dmitry Marakasov <amdmi3@amdmi3.ru>
+Date: Tue, 1 Mar 2016 13:54:12 +0300
+Subject: [PATCH] Only check for BOOST_GCC when it's defined
+
+This fixes warnings with clang:
+
+/usr/local/include/boost/tuple/detail/tuple_basic.hpp:44:5: warning: 'BOOST_GCC' is not defined, evaluates to 0 [-Wundef]
+---
+ include/boost/tuple/detail/tuple_basic.hpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/include/boost/tuple/detail/tuple_basic.hpp b/include/boost/tuple/detail/tuple_basic.hpp
+index 9a3b34e..a688309 100644
+--- a/a/include/boost/tuple/detail/tuple_basic.hpp
++++ b/b/include/boost/tuple/detail/tuple_basic.hpp
+@@ -41,7 +41,7 @@
+
+ #include "boost/detail/workaround.hpp" // needed for BOOST_WORKAROUND
+
+-#if BOOST_GCC >= 40700
++#if defined(BOOST_GCC) && (BOOST_GCC >= 40700)
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wunused-local-typedefs"
+ #endif
+@@ -979,7 +979,7 @@ inline void swap(tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>& lhs,
+ } // end of namespace boost
+
+
+-#if BOOST_GCC >= 40700
++#if defined(BOOST_GCC) && (BOOST_GCC >= 40700)
+ #pragma GCC diagnostic pop
+ #endif
+