aboutsummaryrefslogtreecommitdiff
path: root/net-p2p/libtorrent
diff options
context:
space:
mode:
authorDanilo G. Baio <dbaio@FreeBSD.org>2018-07-24 00:33:28 +0000
committerDanilo G. Baio <dbaio@FreeBSD.org>2018-07-24 00:33:28 +0000
commit1b4848d8c125c3836643c00bd66e61695058167f (patch)
tree44eeff5a7e3367e442ab483df27e88ef4d7418cf /net-p2p/libtorrent
parentdf9c6300e437ef4ed6eeabe4013b8811e614e1f5 (diff)
downloadports-1b4848d8c125c3836643c00bd66e61695058167f.tar.gz
ports-1b4848d8c125c3836643c00bd66e61695058167f.zip
net-p2p/libtorrent: Update to 0.13.7
- IPv6 is not a configure option anymore. - Remove outdated patches. - Remove CONFLICTS, rblibtorrent moved to libtorrent-rasterbar and libtorrent does not conflict with it. - Reset maintainer, three timeouts. PR: 229553 Reported by: tj@mrsk.me (email) Approved by: maintainer timeout (pipfstarrd@openmailbox.org, > 2 weeks)
Notes
Notes: svn path=/head/; revision=475215
Diffstat (limited to 'net-p2p/libtorrent')
-rw-r--r--net-p2p/libtorrent/Makefile22
-rw-r--r--net-p2p/libtorrent/distinfo6
-rw-r--r--net-p2p/libtorrent/files/extra-clang144
-rw-r--r--net-p2p/libtorrent/files/patch-fix-build-bencoders-callers-crash45
-rw-r--r--net-p2p/libtorrent/files/patch-src_net_socket__set.h18
-rw-r--r--net-p2p/libtorrent/files/patch-src_torrent_net_socket__address__key.h10
-rw-r--r--net-p2p/libtorrent/pkg-plist6
7 files changed, 24 insertions, 227 deletions
diff --git a/net-p2p/libtorrent/Makefile b/net-p2p/libtorrent/Makefile
index f4bb874c9b79..75a74303682d 100644
--- a/net-p2p/libtorrent/Makefile
+++ b/net-p2p/libtorrent/Makefile
@@ -1,10 +1,9 @@
# $FreeBSD$
PORTNAME= libtorrent
-PORTVERSION= 0.13.6
-PORTREVISION= 5
+PORTVERSION= 0.13.7
CATEGORIES= net-p2p
-MASTER_SITES= http://rtorrent.net/downloads/
+MASTER_SITES= https://rtorrent.net/downloads/
MAINTAINER= pipfstarrd@openmailbox.org
COMMENT= BitTorrent Library written in C++
@@ -14,17 +13,14 @@ LICENSE_FILE= ${WRKSRC}/COPYING
BROKEN_SSL= openssl-devel
-CONFLICTS_INSTALL= rblibtorrent-[0-9]* rblibtorrent-devel-[0-9]*
-
-USES= compiler:c++11-lang libtool pathfix pkgconfig ssl
+USES= autoreconf:build compiler:c++11-lang libtool pathfix pkgconfig ssl
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --disable-debug
CONFIGURE_ENV= OPENSSL_LIBS="-L${OPENSSLLIB} -lcrypto" OPENSSL_CFLAGS="-I\
${OPENSSLINC}"
-INSTALL_TARGET= install-strip
USE_LDCONFIG= yes
-OPTIONS_DEFINE= IPV6 KQUEUE
+OPTIONS_DEFINE= KQUEUE
OPTIONS_DEFAULT=KQUEUE
KQUEUE_DESC= Use kqueue(2) support
@@ -32,7 +28,6 @@ KQUEUE_DESC= Use kqueue(2) support
# linking libtorrent to avoid linking with base's libcrypto.
MAKE_ARGS= LDFLAGS="${LDFLAGS}"
-IPV6_CONFIGURE_ENABLE= ipv6
KQUEUE_CONFIGURE_WITH= kqueue
.include <bsd.port.pre.mk>
@@ -45,12 +40,6 @@ KQUEUE_CONFIGURE_WITH= kqueue
CONFIGURE_ARGS+=--disable-instrumentation
.endif
-# Workaround to build on >= 10.x
-.if ${OPSYS} == FreeBSD
-USE_CXXSTD= c++11
-EXTRA_PATCHES+= ${FILESDIR}/extra-clang
-.endif
-
post-patch:
.if ${OPSYS} == FreeBSD
@${FIND} ${WRKSRC} \( -name '*.h' -o -name '*.cc' \) -type f \
@@ -63,4 +52,7 @@ post-patch:
${WRKSRC}/src/torrent/utils/log.cc
.endif
+post-install:
+ @${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libtorrent.so.20.0.0
+
.include <bsd.port.post.mk>
diff --git a/net-p2p/libtorrent/distinfo b/net-p2p/libtorrent/distinfo
index fe54e4bcd6f2..c6264faa2a3a 100644
--- a/net-p2p/libtorrent/distinfo
+++ b/net-p2p/libtorrent/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1518295243
-SHA256 (libtorrent-0.13.6.tar.gz) = 2838a08c96edfd936aff8fbf99ecbb930c2bfca3337dd1482eb5fccdb80d5a04
-SIZE (libtorrent-0.13.6.tar.gz) = 781253
+TIMESTAMP = 1529447240
+SHA256 (libtorrent-0.13.7.tar.gz) = c738f60f4d7b6879cd2745fb4310bf24c9287219c1fd619706a9d5499ca7ecc1
+SIZE (libtorrent-0.13.7.tar.gz) = 782854
diff --git a/net-p2p/libtorrent/files/extra-clang b/net-p2p/libtorrent/files/extra-clang
deleted file mode 100644
index f4070b9cb886..000000000000
--- a/net-p2p/libtorrent/files/extra-clang
+++ /dev/null
@@ -1,144 +0,0 @@
---- src/data/memory_chunk.cc
-+++ src/data/memory_chunk.cc
-@@ -54,6 +54,22 @@
-
- namespace torrent {
-
-+const int MemoryChunk::prot_exec;
-+const int MemoryChunk::prot_read;
-+const int MemoryChunk::prot_write;
-+const int MemoryChunk::prot_none;
-+const int MemoryChunk::map_shared;
-+
-+const int MemoryChunk::advice_normal;
-+const int MemoryChunk::advice_random;
-+const int MemoryChunk::advice_sequential;
-+const int MemoryChunk::advice_willneed;
-+const int MemoryChunk::advice_dontneed;
-+
-+const int MemoryChunk::sync_sync;
-+const int MemoryChunk::sync_async;
-+const int MemoryChunk::sync_invalidate;
-+
- uint32_t MemoryChunk::m_pagesize = getpagesize();
-
- inline void
---- src/protocol/request_list.cc
-+++ src/protocol/request_list.cc
-@@ -52,6 +52,8 @@
-
- namespace torrent {
-
-+const int request_list_constants::bucket_count;
-+
- const instrumentation_enum request_list_constants::instrumentation_added[bucket_count] = {
- INSTRUMENTATION_TRANSFER_REQUESTS_QUEUED_ADDED,
- INSTRUMENTATION_TRANSFER_REQUESTS_UNORDERED_ADDED,
---- src/torrent/data/file.cc
-+++ src/torrent/data/file.cc
-@@ -50,6 +50,15 @@
-
- namespace torrent {
-
-+const int File::flag_active;
-+const int File::flag_create_queued;
-+const int File::flag_resize_queued;
-+const int File::flag_fallocate;
-+const int File::flag_previously_created;
-+
-+const int File::flag_prioritize_first;
-+const int File::flag_prioritize_last;
-+
- File::File() :
- m_fd(-1),
- m_protection(0),
---- src/torrent/download.cc
-+++ src/torrent/download.cc
-@@ -72,6 +72,20 @@
-
- namespace torrent {
-
-+const int DownloadInfo::flag_open;
-+const int DownloadInfo::flag_active;
-+const int DownloadInfo::flag_compact;
-+const int DownloadInfo::flag_accepting_new_peers;
-+const int DownloadInfo::flag_accepting_seeders;
-+const int DownloadInfo::flag_private;
-+const int DownloadInfo::flag_meta_download;
-+const int DownloadInfo::flag_pex_enabled;
-+const int DownloadInfo::flag_pex_active;
-+
-+const int DownloadInfo::public_flags;
-+
-+const uint32_t DownloadInfo::unlimited;
-+
- const DownloadInfo* Download::info() const { return m_ptr->info(); }
- const download_data* Download::data() const { return m_ptr->data(); }
-
---- src/torrent/peer/connection_list.cc
-+++ src/torrent/peer/connection_list.cc
-@@ -60,6 +60,11 @@
-
- namespace torrent {
-
-+const int ConnectionList::disconnect_available;
-+const int ConnectionList::disconnect_quick;
-+const int ConnectionList::disconnect_unwanted;
-+const int ConnectionList::disconnect_delayed;
-+
- ConnectionList::ConnectionList(DownloadMain* download) :
- m_download(download), m_minSize(50), m_maxSize(100) {
- }
---- src/torrent/utils/log.cc
-+++ src/torrent/utils/log.cc
-@@ -189,7 +189,7 @@
- pthread_mutex_lock(&log_mutex);
- std::for_each(m_first, m_last, std::tr1::bind(&log_slot::operator(),
- std::tr1::placeholders::_1,
-- buffer,
-+ (const char*)buffer,
- std::distance(buffer, first),
- std::distance(log_groups.begin(), this)));
- if (dump_data != NULL)
---- src/utils/instrumentation.h
-+++ src/utils/instrumentation.h
-@@ -39,6 +39,8 @@
-
- #include <tr1/array>
-
-+#include <algorithm>
-+
- #include "torrent/common.h"
- #include "torrent/utils/log.h"
-
-@@ -118,7 +120,7 @@
-
- inline void
- instrumentation_initialize() {
-- instrumentation_values.assign(int64_t());
-+ std::fill(instrumentation_values.begin(), instrumentation_values.end(), int64_t());
- }
-
- inline void
---- src/utils/queue_buckets.h
-+++ src/utils/queue_buckets.h
-@@ -251,7 +251,7 @@
- instrumentation_update(constants::instrumentation_total[idx], -difference);
-
- // Consider moving these to a temporary dequeue before releasing:
-- std::for_each(begin, end, std::tr1::function<void (value_type)>(&constants::template destroy<value_type>));
-+ std::for_each(begin, end, std::tr1::function<void (value_type&)>(&constants::template destroy<value_type>));
- queue_at(idx).erase(begin, end);
- }
-
---- src/torrent/download_info.h
-+++ src/torrent/download_info.h
-@@ -52,7 +52,7 @@
-
- // This will become a Download 'handle' of kinds.
-
--class DownloadInfo {
-+class LIBTORRENT_EXPORT DownloadInfo {
- public:
- typedef std::tr1::function<uint64_t ()> slot_stat_type;
-
diff --git a/net-p2p/libtorrent/files/patch-fix-build-bencoders-callers-crash b/net-p2p/libtorrent/files/patch-fix-build-bencoders-callers-crash
deleted file mode 100644
index 7c2d424e1d8d..000000000000
--- a/net-p2p/libtorrent/files/patch-fix-build-bencoders-callers-crash
+++ /dev/null
@@ -1,45 +0,0 @@
-# https://github.com/rakshasa/libtorrent/pull/99/files
-
---- src/protocol/extensions.cc.orig 2015-08-08 17:01:32.000000000 +0200
-+++ src/protocol/extensions.cc 2017-12-02 01:46:38.522736000 +0100
-@@ -394,7 +394,7 @@
- if (m_download->info()->is_meta_download() || piece >= pieceEnd) {
- // reject: { "msg_type" => 2, "piece" => ... }
- m_pendingType = UT_METADATA;
-- m_pending = build_bencode(40, "d8:msg_typei2e5:piecei%zuee", piece);
-+ m_pending = build_bencode(sizeof(size_t) + 36, "d8:msg_typei2e5:piecei%zuee", piece);
- return;
- }
-
-@@ -407,7 +407,7 @@
- // data: { "msg_type" => 1, "piece" => ..., "total_size" => ... } followed by piece data (outside of dictionary)
- size_t length = piece == pieceEnd - 1 ? m_download->info()->metadata_size() % metadata_piece_size : metadata_piece_size;
- m_pendingType = UT_METADATA;
-- m_pending = build_bencode(length + 128, "d8:msg_typei1e5:piecei%zue10:total_sizei%zuee", piece, metadataSize);
-+ m_pending = build_bencode((2 * sizeof(size_t)) + length + 120, "d8:msg_typei1e5:piecei%zue10:total_sizei%zuee", piece, metadataSize);
-
- memcpy(m_pending.end(), buffer + (piece << metadata_piece_shift), length);
- m_pending.set(m_pending.data(), m_pending.end() + length, m_pending.owned());
---- src/protocol/handshake.cc.orig 2015-08-08 17:01:49.000000000 +0200
-+++ src/protocol/handshake.cc 2017-12-02 01:46:38.523093000 +0100
-@@ -738,7 +738,7 @@
- break;
-
- if (m_readBuffer.remaining() > m_encryption.length_ia())
-- throw internal_error("Read past initial payload after incoming encrypted handshake.");
-+ throw handshake_error(ConnectionManager::handshake_failed, e_handshake_invalid_value);
-
- if (m_encryption.crypto() != HandshakeEncryption::crypto_rc4)
- m_encryption.info()->set_obfuscated();
---- src/torrent/object_stream.cc.orig 2015-08-08 17:01:32.000000000 +0200
-+++ src/torrent/object_stream.cc 2017-12-02 01:46:38.523350000 +0100
-@@ -104,7 +104,8 @@
- while (first != last && *first >= '0' && *first <= '9')
- length = length * 10 + (*first++ - '0');
-
-- if (length + 1 > (unsigned int)std::distance(first, last) || *first++ != ':')
-+ if (length + 1 > (unsigned int)std::distance(first, last) || *first++ != ':'
-+ || length + 1 == 0)
- throw torrent::bencode_error("Invalid bencode data.");
-
- return raw_string(first, length);
diff --git a/net-p2p/libtorrent/files/patch-src_net_socket__set.h b/net-p2p/libtorrent/files/patch-src_net_socket__set.h
deleted file mode 100644
index 257dbf235766..000000000000
--- a/net-p2p/libtorrent/files/patch-src_net_socket__set.h
+++ /dev/null
@@ -1,18 +0,0 @@
---- src/net/socket_set.h.orig 2012-01-19 10:19:26 UTC
-+++ src/net/socket_set.h
-@@ -53,12 +53,12 @@
-
- // Propably should rename to EventSet...
-
--class SocketSet : private std::vector<Event*, rak::cacheline_allocator<> > {
-+class SocketSet : private std::vector<Event*, rak::cacheline_allocator<Event *> > {
- public:
- typedef uint32_t size_type;
-
-- typedef std::vector<Event*, rak::cacheline_allocator<> > base_type;
-- typedef std::vector<size_type, rak::cacheline_allocator<> > Table;
-+ typedef std::vector<Event*, rak::cacheline_allocator<Event *> > base_type;
-+ typedef std::vector<size_type, rak::cacheline_allocator<size_type> > Table;
-
- static const size_type npos = static_cast<size_type>(-1);
-
diff --git a/net-p2p/libtorrent/files/patch-src_torrent_net_socket__address__key.h b/net-p2p/libtorrent/files/patch-src_torrent_net_socket__address__key.h
new file mode 100644
index 000000000000..cf23b993d598
--- /dev/null
+++ b/net-p2p/libtorrent/files/patch-src_torrent_net_socket__address__key.h
@@ -0,0 +1,10 @@
+--- src/torrent/net/socket_address_key.h.orig 2018-07-03 23:50:04 UTC
++++ src/torrent/net/socket_address_key.h
+@@ -7,6 +7,7 @@
+ #include <cstring>
+ #include <inttypes.h>
+ #include <netinet/in.h>
++#include <sys/socket.h>
+
+ // Unique key for the socket address, excluding port numbers, etc.
+
diff --git a/net-p2p/libtorrent/pkg-plist b/net-p2p/libtorrent/pkg-plist
index 20df140ff81d..9ea98b1b4928 100644
--- a/net-p2p/libtorrent/pkg-plist
+++ b/net-p2p/libtorrent/pkg-plist
@@ -27,6 +27,7 @@ include/torrent/event.h
include/torrent/exceptions.h
include/torrent/hash_string.h
include/torrent/http.h
+include/torrent/net/socket_address_key.h
include/torrent/object.h
include/torrent/object_raw_bencode.h
include/torrent/object_static_map.h
@@ -49,6 +50,7 @@ include/torrent/torrent.h
include/torrent/tracker.h
include/torrent/tracker_controller.h
include/torrent/tracker_list.h
+include/torrent/utils/directory_events.h
include/torrent/utils/extents.h
include/torrent/utils/log.h
include/torrent/utils/log_buffer.h
@@ -59,7 +61,7 @@ include/torrent/utils/resume.h
include/torrent/utils/signal_bitfield.h
include/torrent/utils/thread_base.h
include/torrent/utils/thread_interrupt.h
+include/torrent/utils/uri_parser.h
lib/libtorrent.so
-lib/libtorrent.so.19
-lib/libtorrent.so.19.0.0
+lib/libtorrent.so.20.0.0
libdata/pkgconfig/libtorrent.pc