diff -Nru net-p2p/libtorrent.orig/Makefile net-p2p/libtorrent/Makefile --- net-p2p/libtorrent.orig/Makefile 2018-07-30 00:18:44.000000000 +0200 +++ net-p2p/libtorrent/Makefile 2018-11-07 23:41:35.795128000 +0100 @@ -2,7 +2,7 @@ PORTNAME= libtorrent PORTVERSION= 0.13.7 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= net-p2p MASTER_SITES= https://rtorrent.net/downloads/ @@ -41,18 +41,6 @@ CONFIGURE_ARGS+=--disable-instrumentation .endif -post-patch: -.if ${OPSYS} == FreeBSD - @${FIND} ${WRKSRC} \( -name '*.h' -o -name '*.cc' \) -type f \ - -exec ${REINPLACE_CMD} -e 's/tr1::/std::/g' {} \; \ - -exec ${REINPLACE_CMD} -e 's/std::std::/std::/g' {} \; \ - -exec ${REINPLACE_CMD} -e '/namespace tr1/d' {} \; \ - -exec ${REINPLACE_CMD} -e '/include/s,tr1/,,' {} \; - @${REINPLACE_CMD} -e 's/\.assign/.fill/' \ - ${WRKSRC}/src/torrent/utils/extents.h \ - ${WRKSRC}/src/torrent/utils/log.cc -.endif - post-install: @${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libtorrent.so.20.0.0 diff -Nru net-p2p/libtorrent.orig/files/patch-src_net__socket_fd.cc net-p2p/libtorrent/files/patch-src_net__socket_fd.cc --- net-p2p/libtorrent.orig/files/patch-src_net__socket_fd.cc 1970-01-01 01:00:00.000000000 +0100 +++ net-p2p/libtorrent/files/patch-src_net__socket_fd.cc 2018-11-07 23:35:11.036432000 +0100 @@ -0,0 +1,25 @@ + +Fix from Vlad Movchan + +https://github.com/rakshasa/libtorrent/pull/181 + +--- src/net/socket_fd.cc.orig ++++ src/net/socket_fd.cc +@@ -251,7 +251,7 @@ SocketFd::accept(rak::socket_address* sa) { + socklen_t len = sizeof(rak::socket_address); + + if (sa == NULL) { +- return SocketFd(::accept(m_fd, NULL, &len)); ++ return SocketFd(::accept(m_fd, NULL, &len), m_ipv6_socket); + } + + int fd = ::accept(m_fd, sa->c_sockaddr(), &len); +@@ -260,7 +260,7 @@ SocketFd::accept(rak::socket_address* sa) { + *sa = sa->sa_inet6()->normalize_address(); + } + +- return SocketFd(fd); ++ return SocketFd(fd, m_ipv6_socket); + } + + // unsigned int diff -Nru net-p2p/libtorrent.orig/files/patch-src_net__socket_fd.h net-p2p/libtorrent/files/patch-src_net__socket_fd.h --- net-p2p/libtorrent.orig/files/patch-src_net__socket_fd.h 1970-01-01 01:00:00.000000000 +0100 +++ net-p2p/libtorrent/files/patch-src_net__socket_fd.h 2018-11-07 23:36:20.602819000 +0100 @@ -0,0 +1,15 @@ + +Fix from Vlad Movchan + +https://github.com/rakshasa/libtorrent/pull/181 + +--- src/net/socket_fd.h.orig ++++ src/net/socket_fd.h +@@ -51,6 +51,7 @@ class SocketFd { + + SocketFd() : m_fd(-1) {} + explicit SocketFd(int fd) : m_fd(fd) {} ++ SocketFd(int fd, bool ipv6_socket) : m_fd(fd), m_ipv6_socket(ipv6_socket) {} + + bool is_valid() const { return m_fd >= 0; } +