'boost gather several std::vector

I'm need to gather multiple std::vectors each from a different rank with boost::mpi::gather. I have a minimal example working with std::arrays:

mpi::communicator local;
std::array<double,6> aaa{{1,1,1,1,1,1}};
std::vector<std::array<double,6>> bbb; 
mpi::gather(local, aaa, bbb, 0);

but if I use std::vector:

mpi::communicator local;
std::vector<double> aaa {1,1,1,1,1,1};
std::vector<std::vector<double>> bbb{mpi_size};
mpi::gather(local, aaa, bbb, 0);

I get an error during linking. (I have added #include <boost/serialization/vector.hpp>). Is this expected?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source