pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/52969: /usr/pkgsrc/ham/uhd fails to build due to fallout from updated boost



>Number:         52969
>Category:       pkg
>Synopsis:       /usr/pkgsrc/ham/uhd fails to build due to fallout from updated boost
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jan 30 23:15:00 +0000 2018
>Originator:     Dave Tyson
>Release:        current pkgsrc
>Organization:
Anduin
>Environment:
NetBSD dell.anduin.org.uk 8.0_BETA NetBSD 8.0_BETA (GENERIC.201801221730Z) amd64

>Description:
with the boost libs updated to 2.6 there are changes so that socket->native() is no longer supported. use socket->native_handle() instead


>How-To-Repeat:
cd /usr/pkgsrc/ham/uhd
make install
>Fix:
Apply the four patches:

patch-host_examples_network_relay.cpp

--- examples/network_relay.cpp.orig
+++ examples/network_relay.cpp
@@ -127,7 +127,7 @@
         wait_for_thread.notify_one();    // notify constructor that this thread has started
         std::vector<char> buff(insane_mtu);
         while (not boost::this_thread::interruption_requested()){
-            if (wait_for_recv_ready(_server_socket->native())){
+            if (wait_for_recv_ready(_server_socket->native_handle())){
                 boost::mutex::scoped_lock lock(_endpoint_mutex);
                 const size_t len = _server_socket->receive_from(asio::buffer(&buff.front(), buff.size()), _endpoint);
                 lock.unlock();
@@ -153,7 +153,7 @@
         wait_for_thread.notify_one();    // notify constructor that this thread has started
         std::vector<char> buff(insane_mtu);
         while (not boost::this_thread::interruption_requested()){
-            if (wait_for_recv_ready(_client_socket->native())){
+            if (wait_for_recv_ready(_client_socket->native_handle())){
                 const size_t len = _client_socket->receive(asio::buffer(&buff.front(), buff.size()));
                 boost::mutex::scoped_lock lock(_endpoint_mutex);
                 _server_socket->send_to(asio::buffer(&buff.front(), len), _endpoint);

patch-host_lib_transport_tcp_zero_copy.cpp

--- lib/transport/tcp_zero_copy.cpp
+++ lib/transport/tcp_zero_copy.cpp.orig
@@ -154,7 +154,7 @@
         //create, open, and connect the socket
         _socket.reset(new asio::ip::tcp::socket(_io_service));
         _socket->connect(receiver_endpoint);
-        _sock_fd = _socket->native();
+        _sock_fd = _socket->native_handle();
 
         //packets go out ASAP
         asio::ip::tcp::no_delay option(true);

patch-host_lib_transport_udp_simple.cpp

--- lib/transport/udp_simple.cpp.orig
+++ lib/transport/udp_simple.cpp
@@ -56,7 +56,7 @@
     }
 
     size_t recv(const asio::mutable_buffer &buff, double timeout){
-        if (not wait_for_recv_ready(_socket->native(), timeout)) return 0;
+        if (not wait_for_recv_ready(_socket->native_handle(), timeout)) return 0;
         return _socket->receive_from(asio::buffer(buff), _recv_endpoint);
     }

patch-host_lib_transport_udp_zero_copy.cpp

--- lib/transport/udp_zero_copy.cpp.orig
+++ lib/transport/udp_zero_copy.cpp
@@ -190,7 +190,7 @@
         _socket = socket_sptr(new asio::ip::udp::socket(_io_service));
         _socket->open(asio::ip::udp::v4());
         _socket->connect(receiver_endpoint);
-        _sock_fd = _socket->native();
+        _sock_fd = _socket->native_handle();
 
         //allocate re-usable managed receive buffers
         for (size_t i = 0; i < get_num_recv_frames(); i++){



Home | Main Index | Thread Index | Old Index