aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonald Klop <ronald@FreeBSD.org>2023-07-02 18:57:07 +0000
committerRonald Klop <ronald@FreeBSD.org>2023-07-02 18:58:50 +0000
commitd37d341204750f739aed02cae45fe3104272192c (patch)
treec5cf0f315e6406382e0c2117a44701badf35efea
parent7711191a2af6cbba85e19739fdadbceffef0597a (diff)
downloadports-d37d341204750f739aed02cae45fe3104272192c.tar.gz
ports-d37d341204750f739aed02cae45fe3104272192c.zip
databases/mongodb60: fix build with llvm16/clang16
* BOOST_NO_CXX98_FUNCTION_BASE fixes: In file included from src/third_party/boost/boost/functional/hash.hpp:6: src/third_party/boost/boost/container_hash/hash.hpp:131:33: error: no template named 'unary_function' in namespace 'std'; did you mean '__unary_function'? struct hash_base : std::unary_function<T, std::size_t> {}; ~~~~~^~~~~~~~~~~~~~ __unary_function /usr/include/c++/v1/__functional/unary_function.h:46:1: note: '__unary_function' declared here using __unary_function = __unary_function_keep_layout_base<_Arg, _Result>; ^ * And "#if 1" fixes: In file included from src/third_party/boost/boost/mpl/integral_c.hpp:32: src/third_party/boost/boost/mpl/aux_/integral_wrapper.hpp:73:31: error: integer value -1 is outside the valid range of values [0, 3] for the enumeration type 'lock_access_mode' [-Wenum-constexpr-conversion] typedef AUX_WRAPPER_INST( BOOST_MPL_AUX_STATIC_CAST(AUX_WRAPPER_VALUE_TYPE, (value - 1)) ) prior; PR: 272295
-rw-r--r--databases/mongodb60/Makefile2
-rw-r--r--databases/mongodb60/files/patch-src_third__party_boost_boost_mpl_aux___integral__wrapper.hpp11
-rw-r--r--databases/mongodb60/pkg-message8
3 files changed, 21 insertions, 0 deletions
diff --git a/databases/mongodb60/Makefile b/databases/mongodb60/Makefile
index 7d0b40fb3aff..793bfc4951aa 100644
--- a/databases/mongodb60/Makefile
+++ b/databases/mongodb60/Makefile
@@ -47,6 +47,8 @@ GH_PROJECT= mongo spidermonkey:mozjs
GH_TAGNAME= ${MOZJS_TAG}:mozjs
USE_RC_SUBR= mongod
+CFLAGS+= -DBOOST_NO_CXX98_FUNCTION_BASE
+
SHEBANG_FILES= buildscripts/scons.py
python_OLD_CMD= @python_interpreter@
diff --git a/databases/mongodb60/files/patch-src_third__party_boost_boost_mpl_aux___integral__wrapper.hpp b/databases/mongodb60/files/patch-src_third__party_boost_boost_mpl_aux___integral__wrapper.hpp
new file mode 100644
index 000000000000..a45dcb0f2340
--- /dev/null
+++ b/databases/mongodb60/files/patch-src_third__party_boost_boost_mpl_aux___integral__wrapper.hpp
@@ -0,0 +1,11 @@
+--- src/third_party/boost/boost/mpl/aux_/integral_wrapper.hpp.orig 2023-06-30 20:32:00 UTC
++++ src/third_party/boost/boost/mpl/aux_/integral_wrapper.hpp
+@@ -56,7 +56,7 @@ struct AUX_WRAPPER_NAME
+ // have to #ifdef here: some compilers don't like the 'N + 1' form (MSVC),
+ // while some other don't like 'value + 1' (Borland), and some don't like
+ // either
+-#if BOOST_WORKAROUND(__EDG_VERSION__, <= 243)
++#if 1 //BOOST_WORKAROUND(__EDG_VERSION__, <= 243)
+ private:
+ BOOST_STATIC_CONSTANT(AUX_WRAPPER_VALUE_TYPE, next_value = BOOST_MPL_AUX_STATIC_CAST(AUX_WRAPPER_VALUE_TYPE, (N + 1)));
+ BOOST_STATIC_CONSTANT(AUX_WRAPPER_VALUE_TYPE, prior_value = BOOST_MPL_AUX_STATIC_CAST(AUX_WRAPPER_VALUE_TYPE, (N - 1)));
diff --git a/databases/mongodb60/pkg-message b/databases/mongodb60/pkg-message
new file mode 100644
index 000000000000..43e45ca6a35a
--- /dev/null
+++ b/databases/mongodb60/pkg-message
@@ -0,0 +1,8 @@
+[
+{ type: install
+ message: <<EOM
+MongoDB on Rasperry Pi can work but is unsupported upstream.
+Please read https://jira.mongodb.org/browse/SERVER-71772 if you run this on a non-LSE ARM cpu.
+EOM
+}
+]