Index: head/net-p2p/qbittorrent/Makefile =================================================================== --- head/net-p2p/qbittorrent/Makefile (revision 429926) +++ head/net-p2p/qbittorrent/Makefile (revision 429927) @@ -1,88 +1,87 @@ # Created by: Doug Barton # $FreeBSD$ PORTNAME= qbittorrent -PORTVERSION= 3.3.7 -PORTREVISION= 1 +PORTVERSION= 3.3.10 CATEGORIES= net-p2p ipv6 MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION} MAINTAINER= yuri@rawbw.com COMMENT?= Bittorrent client using Qt4/5 and libtorrent-rasterbar LICENSE= GPLv2 LIB_DEPENDS= libtorrent-rasterbar.so:net-p2p/libtorrent-rasterbar \ libboost_system.so:devel/boost-libs USES= compiler:c++11-lib execinfo pkgconfig tar:xz QT4_USE= QT4=corelib,network,xml,qmake_build,linguisttools_build,moc_build,rcc_build,uic_build QT5_USE= QT5=core,network,xml,qmake_build,buildtools_build,linguisttools_build QT_NONSTANDARD= yes DESTDIRNAME= INSTALL_ROOT GNU_CONFIGURE= yes PORTDOCS= AUTHORS Changelog README.md .if !defined(SLAVE_PORT) || ${SLAVE_PORT:tl} == "no" WITH_GUI:= yes .else WITH_GUI:= no .endif OPTIONS_DEFINE= DBUS DEBUG DOCS OPTIONS_SINGLE= QT OPTIONS_SINGLE_QT= QT4 QT5 OPTIONS_DEFAULT= QT5 OPTION_QT= ${SELECTED_OPTIONS:MQT*} DEBUG_CONFIGURE_ENABLE= debug DBUS_CONFIGURE_ENABLE= qt-dbus QT4_CONFIGURE_ON= --with-qt4 .if ${WITH_GUI} == "yes" LIB_DEPENDS+= libGeoIP.so:net/GeoIP USES+= desktop-file-utils QT4_USE+= QT4=gui QT5_USE+= QT5=concurrent,gui,widgets GL=gl OPTIONS_DEFAULT+= DBUS .else CONFIGURE_ARGS+= --disable-gui .endif BROKEN_FreeBSD_9= needs more C++11 support than 9.x offers .include .if ${PORT_OPTIONS:MDBUS} USE_${OPTION_QT}+= dbus .endif CONFIGURE_ARGS+= CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" post-patch: .if ${PORT_OPTIONS:MQT4} ${REINPLACE_CMD} 's,^\$$QT_QMAKE,${LOCALBASE}/bin/qmake-qt4,' \ ${WRKSRC}/${CONFIGURE_SCRIPT} .else ${REINPLACE_CMD} 's,^\$$QT_QMAKE,${LOCALBASE}/lib/qt5/bin/qmake,' \ ${WRKSRC}/${CONFIGURE_SCRIPT} .endif post-install: .if ${WITH_GUI} == "yes" @${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/qbittorrent ${INSTALL_MAN} ${WRKSRC}/doc/qbittorrent.1 \ ${STAGEDIR}${MAN1PREFIX}/man/man1/ .else @${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/qbittorrent-nox ${INSTALL_MAN} ${WRKSRC}/doc/qbittorrent-nox.1 \ ${STAGEDIR}${MAN1PREFIX}/man/man1/ .endif @${RM} -r ${STAGEDIR}${PREFIX}/share/man post-install-DOCS-on: @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR} .include Index: head/net-p2p/qbittorrent/distinfo =================================================================== --- head/net-p2p/qbittorrent/distinfo (revision 429926) +++ head/net-p2p/qbittorrent/distinfo (revision 429927) @@ -1,3 +1,3 @@ -TIMESTAMP = 1473733537 -SHA256 (qbittorrent-3.3.7.tar.xz) = 72dc824a90fadc0825e6be6f1c215e38f976262c7f83b625061d542b2b664c40 -SIZE (qbittorrent-3.3.7.tar.xz) = 2884792 +TIMESTAMP = 1482707995 +SHA256 (qbittorrent-3.3.10.tar.xz) = 2c657ceacdc84033da044a0a9ecba7e0fdb35858324dc097546f989166f1a8d2 +SIZE (qbittorrent-3.3.10.tar.xz) = 2959380 Index: head/net-p2p/qbittorrent/files/patch-src_base_bittorrent_session.cpp =================================================================== --- head/net-p2p/qbittorrent/files/patch-src_base_bittorrent_session.cpp (nonexistent) +++ head/net-p2p/qbittorrent/files/patch-src_base_bittorrent_session.cpp (revision 429927) @@ -0,0 +1,64 @@ +Revert the following commit until libtorrent 1.1.2 is released: + +From 729c80f9104a3d01ec724351bd6910b4b8d14c6c Mon Sep 17 00:00:00 2001 +From: sledgehammer999 +Date: Mon, 31 Oct 2016 02:31:56 +0200 +Subject: [PATCH] Use new libtorrent 1.1.2+ utility function to generate client + ID instead. + +--- src/base/bittorrent/session.cpp.orig 2016-12-17 18:02:06 UTC ++++ src/base/bittorrent/session.cpp +@@ -45,6 +45,7 @@ + #include + + #include ++#include + #include + #include + +@@ -194,6 +195,36 @@ namespace + + template + LowerLimited lowerLimited(T limit, T ret) { return LowerLimited(limit, ret); } ++ ++#if LIBTORRENT_VERSION_NUM >= 10100 ++ std::string makeFingerprint(const char* peerId, int major, int minor, int revision, int tag) ++ { ++ Q_ASSERT(peerId); ++ Q_ASSERT(major >= 0); ++ Q_ASSERT(minor >= 0); ++ Q_ASSERT(revision >= 0); ++ Q_ASSERT(tag >= 0); ++ Q_ASSERT(std::strlen(peerId) == 2); ++ ++ auto versionToChar = [](int v) -> char ++ { ++ if (v >= 0 && v < 10) return static_cast('0' + v); ++ if (v >= 10) return static_cast('A' + (v - 10)); ++ Q_ASSERT(false); ++ return '0'; ++ }; ++ ++ std::ostringstream buf; ++ buf << '-' ++ << peerId ++ << versionToChar(major) ++ << versionToChar(minor) ++ << versionToChar(revision) ++ << versionToChar(tag) ++ << '-'; ++ return buf.str(); ++ } ++#endif + } + + // Session +@@ -334,7 +365,7 @@ Session::Session(QObject *parent) + dispatchAlerts(alertPtr.release()); + }); + #else +- std::string peerId = libt::generate_fingerprint(PEER_ID, VERSION_MAJOR, VERSION_MINOR, VERSION_BUGFIX, VERSION_BUILD); ++ std::string peerId = makeFingerprint(PEER_ID, VERSION_MAJOR, VERSION_MINOR, VERSION_BUGFIX, VERSION_BUILD); + libt::settings_pack pack; + pack.set_int(libt::settings_pack::alert_mask, alertMask); + pack.set_str(libt::settings_pack::peer_fingerprint, peerId); Property changes on: head/net-p2p/qbittorrent/files/patch-src_base_bittorrent_session.cpp ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/net-p2p/qbittorrent/files/patch-src_base_utils_string.cpp =================================================================== --- head/net-p2p/qbittorrent/files/patch-src_base_utils_string.cpp (revision 429926) +++ head/net-p2p/qbittorrent/files/patch-src_base_utils_string.cpp (revision 429927) @@ -1,31 +1,33 @@ ---- src/base/utils/string.cpp.orig 2016-09-23 15:05:18 UTC +Avoid use of thread local storage on versions prior to which it was supported. + +--- src/base/utils/string.cpp.orig 2016-12-17 18:02:06 UTC +++ src/base/utils/string.cpp @@ -37,7 +37,7 @@ #ifdef QBT_USES_QT5 #include #endif -#ifdef Q_OS_MAC +#if defined(Q_OS_MAC) || (defined(__FreeBSD__) && __FreeBSD_version < 1003506) #include #endif @@ -146,7 +146,8 @@ bool Utils::String::naturalCompareCaseSe { // provide a single `NaturalCompare` instance for easy use // https://doc.qt.io/qt-5/threads-reentrancy.html -#ifdef Q_OS_MAC // workaround for Apple xcode: https://stackoverflow.com/a/29929949 +#if defined(Q_OS_MAC) || (defined(__FreeBSD__) && __FreeBSD_version < 1003506) +// workaround for Apple xcode: https://stackoverflow.com/a/29929949 static QThreadStorage nCmp; if (!nCmp.hasLocalData()) nCmp.setLocalData(NaturalCompare(true)); return (nCmp.localData())(left, right); @@ -160,7 +161,8 @@ bool Utils::String::naturalCompareCaseIn { // provide a single `NaturalCompare` instance for easy use // https://doc.qt.io/qt-5/threads-reentrancy.html -#ifdef Q_OS_MAC // workaround for Apple xcode: https://stackoverflow.com/a/29929949 +#if defined(Q_OS_MAC) || (defined(__FreeBSD__) && __FreeBSD_version < 1003506) +// workaround for Apple xcode: https://stackoverflow.com/a/29929949 static QThreadStorage nCmp; if (!nCmp.hasLocalData()) nCmp.setLocalData(NaturalCompare(false)); return (nCmp.localData())(left, right);