net-wireless/gnuradio: Fix building against boost 1.70
authorDavid Seifert <soap@gentoo.org>
Sun, 26 May 2019 09:27:58 +0000 (11:27 +0200)
committerDavid Seifert <soap@gentoo.org>
Sun, 26 May 2019 09:27:58 +0000 (11:27 +0200)
* Patch adapted from FreeBSD with whitespace cleanup

Closes: https://bugs.gentoo.org/683380
Package-Manager: Portage-2.3.66, Repoman-2.3.12
Signed-off-by: David Seifert <soap@gentoo.org>
net-wireless/gnuradio/files/gnuradio-3.7.13.5-boost-1.70-asio.patch [new file with mode: 0644]
net-wireless/gnuradio/gnuradio-3.7.13.5.ebuild

diff --git a/net-wireless/gnuradio/files/gnuradio-3.7.13.5-boost-1.70-asio.patch b/net-wireless/gnuradio/files/gnuradio-3.7.13.5-boost-1.70-asio.patch
new file mode 100644 (file)
index 0000000..d4925e6
--- /dev/null
@@ -0,0 +1,18 @@
+Bug: https://bugs.gentoo.org/683380
+Patch adapted from FreeBSD:
+https://svnweb.freebsd.org/ports/head/comms/gnuradio/files/patch-gr-blocks_lib_socket__pdu__impl.cc?view=markup&pathrev=499093
+
+--- a/gr-blocks/lib/socket_pdu_impl.cc
++++ b/gr-blocks/lib/socket_pdu_impl.cc
+@@ -165,7 +165,11 @@
+     void
+     socket_pdu_impl::start_tcp_accept()
+     {
++#if (BOOST_VERSION >= 107000)
++      tcp_connection::sptr new_connection = tcp_connection::make(d_io_service, d_rxbuf.size(), d_tcp_no_delay);
++#else
+       tcp_connection::sptr new_connection = tcp_connection::make(d_acceptor_tcp->get_io_service(), d_rxbuf.size(), d_tcp_no_delay);
++#endif
+       d_acceptor_tcp->async_accept(new_connection->socket(),
+         boost::bind(&socket_pdu_impl::handle_tcp_accept, this,
index 354d6e7b959a5d91687896378b86d4d52d13d2e0..6879265094646254b7720317960cd01ba72567e1 100644 (file)
@@ -49,7 +49,7 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE}
 # boost-1.52.0 is blacklisted, bug #461578, upstream #513, boost #7669
 RDEPEND="${PYTHON_DEPS}
        >=dev-lang/orc-0.4.12
-       dev-libs/boost:0=[${PYTHON_USEDEP}]
+       dev-libs/boost:0=[python,${PYTHON_USEDEP}]
        !<=dev-libs/boost-1.52.0-r6:0/1.52
        dev-python/mako[${PYTHON_USEDEP}]
        dev-python/six[${PYTHON_USEDEP}]
@@ -120,6 +120,7 @@ src_prepare() {
        sed -i '/qPixmapFromMimeSource/d' "${S}"/gr-qtgui/lib/spectrumdisplayform.ui || die
        epatch "${WORKDIR}"/qt5-maint-00*.patch
        epatch "${WORKDIR}"/codec2-next-00*.patch
+       epatch "${FILESDIR}"/${PN}-3.7.13.5-boost-1.70-asio.patch
 
        use !alsa && sed -i 's#version.h#version-nonexistant.h#' cmake/Modules/FindALSA.cmake
        use !jack && sed -i 's#jack.h#jack-nonexistant.h#' cmake/Modules/FindJack.cmake