Hi, my boost-libs + MPI patch did not get merged because boost-mpi is broken in 1.64. They know it. There is a fix. So here is a patchset (also on [1] with others) that - adds MPI option to boost-libs and - applies the build fix for boost MPI code. They work with 2017Q2 for me. Oh, and for good measure, I also attach my patch to build my RPATH into boost stuff. This is vital for the kind of setup I run, with a prepared toolchain that then builds pkgsrc. I assume it does no harm for others. I also carry a patch that simply re-enables the heuristic for building fiber. On my GNU/Linux systems with GCC 6.x I did not see trouble there. You might want to revisit that, too. I'm off now seeing what causes the horrible breakage with Qt5 stuff later on (unsupported reloc 42 on one box). Alrighty then, Thomas [1] http://src.rrz.uni-hamburg.de/extra/pkgsrc-patches/ -- Dr. Thomas Orgis Universität Hamburg RRZ / Basis-Infrastruktur / HPC Schlüterstr. 70 20146 Hamburg Tel.: 040/42838 8826 Fax: 040/428 38 6270
diff -ruN -x CVS pkgsrc-2016Q4/devel/boost-jam/bjam.mk pkgsrc/devel/boost-jam/bjam.mk --- pkgsrc-2016Q4/devel/boost-jam/bjam.mk 2016-02-29 00:54:11.000000000 +0100 +++ pkgsrc/devel/boost-jam/bjam.mk 2017-03-16 15:32:24.260884756 +0100 @@ -43,6 +43,10 @@ BJAM_BUILD+= threading=multi BJAM_BUILD+= link=shared,static +# Support RPATH in generated libs for paths mentioned in LDFLAGS. +BJAM_ARGS+= hardcode-dll-paths=true +BJAM_ARGS+= ${BUILDLINK_PASSTHRU_RPATHDIRS:@p@dll-path=${p}@} + BJAM_CMD= ${SETENV} ${MAKE_ENV} ${BJAM} ${BJAM_ARGS} UNLIMIT_RESOURCES+= datasize
Index: Makefile =================================================================== RCS file: /cvsroot/pkgsrc/devel/boost-libs/Makefile,v retrieving revision 1.56 diff -u -r1.56 Makefile --- devel/boost-libs/Makefile 29 May 2017 14:39:28 -0000 1.56 +++ devel/boost-libs/Makefile 14 Jul 2017 15:35:06 -0000 @@ -13,6 +13,8 @@ BJAM_ARGS+= --without-python PLIST_VARS+= context fiber log +.include "options.mk" + .if ${OPSYS} == "NetBSD" && ((${MACHINE_ARCH} == "i386") || (!empty(MACHINE_ARCH:Mearm*) && !empty(PKGSRC_COMPILER:Mgcc))) BJAM_ARGS+= pch=off .endif Index: PLIST =================================================================== RCS file: /cvsroot/pkgsrc/devel/boost-libs/PLIST,v retrieving revision 1.34 diff -u -r1.34 PLIST --- devel/boost-libs/PLIST 29 Apr 2017 18:31:42 -0000 1.34 +++ devel/boost-libs/PLIST 14 Jul 2017 15:35:06 -0000 @@ -97,3 +97,9 @@ lib/libboost_wserialization.a lib/libboost_wserialization.so lib/libboost_wserialization.so.${BOOST_VERSION} +${PLIST.mpi}lib/libboost_graph_parallel.a +${PLIST.mpi}lib/libboost_graph_parallel.so +${PLIST.mpi}lib/libboost_graph_parallel.so.${BOOST_VERSION} +${PLIST.mpi}lib/libboost_mpi.a +${PLIST.mpi}lib/libboost_mpi.so +${PLIST.mpi}lib/libboost_mpi.so.${BOOST_VERSION} Index: options.mk =================================================================== RCS file: options.mk diff -N options.mk --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ devel/boost-libs/options.mk 14 Jul 2017 15:35:06 -0000 @@ -0,0 +1,21 @@ +PKG_OPTIONS_VAR= PKG_OPTIONS.boost +PKG_SUPPORTED_OPTIONS= mpi +PKG_SUGGESTED_OPTIONS= + +PLIST_VARS+= mpi + +.include "../../mk/bsd.options.mk" + +.if !empty(PKG_OPTIONS:Mmpi) + +# Need to enable MPI behind the scenes. +mpihackery: + echo "using mpi ;" >> ${WRKSRC}/project-config.jam + +pre-configure: mpihackery + +.include "../../mk/mpi.buildlink3.mk" + +PLIST.mpi= yes + +.endif
Index: distinfo =================================================================== RCS file: /cvsroot/pkgsrc/meta-pkgs/boost/distinfo,v retrieving revision 1.102 diff -u -r1.102 distinfo --- meta-pkgs/boost/distinfo 14 Jul 2017 17:35:07 -0000 1.102 +++ meta-pkgs/boost/distinfo 15 Jul 2017 11:12:00 -0000 @@ -25,3 +25,4 @@ SHA1 (patch-libs_config_configure) = e2f204d4fa4f1bd9b4131d28f9be0a1ac22bf711 SHA1 (patch-libs_config_test_boost__no__range__based__for.ipp) = d9936c472fc2c696d86522b36eb12813ae91bee4 SHA1 (patch-libs_fiber_build_Jamfile.v2) = 28c1aba2d074f2db7104e37cd900d33f5fcffb09 +SHA1 (patch-libs_mpi_fix_get_data) = 4133910750a5c719c711b3509995983c7358bd74 Index: patches/patch-libs_mpi_fix_get_data =================================================================== RCS file: patches/patch-libs_mpi_fix_get_data diff -N patches/patch-libs_mpi_fix_get_data --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ meta-pkgs/boost/patches/patch-libs_mpi_fix_get_data 15 Jul 2017 11:12:00 -0000 @@ -0,0 +1,120 @@ +From f5bdcc1ebfe954bb64835f2a0efd94471da42207 Mon Sep 17 00:00:00 2001 +From: Jonathan Wakely <github%kayari.org@localhost> +Date: Thu, 23 Feb 2017 02:18:58 +0000 +Subject: [PATCH] Replace boost::serialization::detail::get_data function. + (#39) + +--- + include/boost/mpi/detail/mpi_datatype_primitive.hpp | 19 ++++++++++++------- + include/boost/mpi/detail/packed_iprimitive.hpp | 8 ++++++-- + include/boost/mpi/detail/packed_oprimitive.hpp | 8 ++++++-- + 3 files changed, 24 insertions(+), 11 deletions(-) + +diff --git a/include/boost/mpi/detail/mpi_datatype_primitive.hpp b/include/boost/mpi/detail/mpi_datatype_primitive.hpp +index c230055..b95fc38 100644 +--- boost/mpi/detail/mpi_datatype_primitive.hpp ++++ boost/mpi/detail/mpi_datatype_primitive.hpp +@@ -25,7 +25,6 @@ namespace std{ + #include <boost/assert.hpp> + #include <boost/mpl/placeholders.hpp> + #include <boost/serialization/array.hpp> +-#include <boost/serialization/detail/get_data.hpp> + #include <stdexcept> + #include <iostream> + #include <vector> +@@ -80,18 +79,18 @@ class mpi_datatype_primitive + BOOST_MPI_CHECK_RESULT(MPI_Type_create_struct, + ( + addresses.size(), +- boost::serialization::detail::get_data(lengths), +- boost::serialization::detail::get_data(addresses), +- boost::serialization::detail::get_data(types), ++ get_data(lengths), ++ get_data(addresses), ++ get_data(types), + &datatype_ + )); + #else + BOOST_MPI_CHECK_RESULT(MPI_Type_struct, + ( + addresses.size(), +- boost::serialization::detail::get_data(lengths), +- boost::serialization::detail::get_data(addresses), +- boost::serialization::detail::get_data(types), ++ get_data(lengths), ++ get_data(addresses), ++ get_data(types), + &datatype_ + )); + #endif +@@ -129,6 +128,12 @@ class mpi_datatype_primitive + lengths.push_back(l); + } + ++ template <class T> ++ static T* get_data(std::vector<T>& v) ++ { ++ return v.empty() ? 0 : &(v[0]); ++ } ++ + std::vector<MPI_Aint> addresses; + std::vector<MPI_Datatype> types; + std::vector<int> lengths; +diff --git a/include/boost/mpi/detail/packed_iprimitive.hpp b/include/boost/mpi/detail/packed_iprimitive.hpp +index 7080cbf..227dc8e 100644 +--- boost/mpi/detail/packed_iprimitive.hpp ++++ boost/mpi/detail/packed_iprimitive.hpp +@@ -16,7 +16,6 @@ + #include <boost/mpi/exception.hpp> + #include <boost/assert.hpp> + #include <boost/serialization/array.hpp> +-#include <boost/serialization/detail/get_data.hpp> + #include <vector> + #include <boost/mpi/allocator.hpp> + +@@ -104,7 +103,12 @@ class BOOST_MPI_DECL packed_iprimitive + void load_impl(void * p, MPI_Datatype t, int l) + { + BOOST_MPI_CHECK_RESULT(MPI_Unpack, +- (const_cast<char*>(boost::serialization::detail::get_data(buffer_)), buffer_.size(), &position, p, l, t, comm)); ++ (get_data(buffer_), buffer_.size(), &position, p, l, t, comm)); ++ } ++ ++ static buffer_type::value_type* get_data(buffer_type& b) ++ { ++ return b.empty() ? 0 : &(b[0]); + } + + buffer_type & buffer_; +diff --git a/include/boost/mpi/detail/packed_oprimitive.hpp b/include/boost/mpi/detail/packed_oprimitive.hpp +index fbcde9a..3c81a70 100644 +--- boost/mpi/detail/packed_oprimitive.hpp ++++ boost/mpi/detail/packed_oprimitive.hpp +@@ -15,7 +15,6 @@ + + #include <boost/mpi/datatype.hpp> + #include <boost/mpi/exception.hpp> +-#include <boost/serialization/detail/get_data.hpp> + #include <boost/serialization/array.hpp> + #include <boost/assert.hpp> + #include <vector> +@@ -103,13 +102,18 @@ class BOOST_MPI_DECL packed_oprimitive + + // pack the data into the buffer + BOOST_MPI_CHECK_RESULT(MPI_Pack, +- (const_cast<void*>(p), l, t, boost::serialization::detail::get_data(buffer_), buffer_.size(), &position, comm)); ++ (const_cast<void*>(p), l, t, get_data(buffer_), buffer_.size(), &position, comm)); + // reduce the buffer size if needed + BOOST_ASSERT(std::size_t(position) <= buffer_.size()); + if (std::size_t(position) < buffer_.size()) + buffer_.resize(position); + } + ++ static buffer_type::value_type* get_data(buffer_type& b) ++ { ++ return b.empty() ? 0 : &(b[0]); ++ } ++ + buffer_type& buffer_; + mutable std::size_t size_; + MPI_Comm comm;
Attachment:
smime.p7s
Description: S/MIME cryptographic signature