diff --git a/fix-build-with-newer-kconfig.diff b/fix-build-with-newer-kconfig.diff deleted file mode 100644 index bdb2c07..0000000 --- a/fix-build-with-newer-kconfig.diff +++ /dev/null @@ -1,94 +0,0 @@ -diff --git a/ktorrent/dialogs/pastedialog.cpp b/ktorrent/dialogs/pastedialog.cpp -index d0f08e9..4708bca 100644 ---- a/ktorrent/dialogs/pastedialog.cpp -+++ b/ktorrent/dialogs/pastedialog.cpp -@@ -73,14 +73,14 @@ namespace kt - m_groups->addItems(grps); - } - -- void PasteDialog::loadState(KSharedConfigPtr cfg) -+ void PasteDialog::loadState(KSharedConfig::Ptr cfg) - { - KConfigGroup g = cfg->group("PasteDlg"); - m_silently->setChecked(g.readEntry("silently", false)); - m_groups->setCurrentIndex(g.readEntry("group", 0)); - } - -- void PasteDialog::saveState(KSharedConfigPtr cfg) -+ void PasteDialog::saveState(KSharedConfig::Ptr cfg) - { - KConfigGroup g = cfg->group("PasteDlg"); - g.writeEntry("silently", m_silently->isChecked()); -diff --git a/ktorrent/dialogs/pastedialog.h b/ktorrent/dialogs/pastedialog.h -index 2446848..0c9a65b 100644 ---- a/ktorrent/dialogs/pastedialog.h -+++ b/ktorrent/dialogs/pastedialog.h -@@ -22,6 +22,7 @@ - #define PASTEDIALOG_H - - #include -+#include - #include "ui_pastedlgbase.h" - - -@@ -43,12 +44,12 @@ namespace kt - /** - * Load the state of the dialog - */ -- void loadState(KSharedConfigPtr cfg); -+ void loadState(KSharedConfig::Ptr cfg); - - /** - * Save the state of the dialog - */ -- void saveState(KSharedConfigPtr cfg); -+ void saveState(KSharedConfig::Ptr cfg); - - public slots: - virtual void accept(); -diff --git a/plugins/mediaplayer/mediaview.cpp b/plugins/mediaplayer/mediaview.cpp -index d805c4b..0cbd901 100644 ---- a/plugins/mediaplayer/mediaview.cpp -+++ b/plugins/mediaplayer/mediaview.cpp -@@ -146,7 +146,7 @@ namespace kt - filter->setShowIncomplete(on); - } - -- void MediaView::loadState(KSharedConfigPtr cfg) -+ void MediaView::loadState(KSharedConfig::Ptr cfg) - { - KConfigGroup g = cfg->group("MediaView"); - show_incomplete->setChecked(g.readEntry("show_incomplete", false)); -@@ -154,7 +154,7 @@ namespace kt - - } - -- void MediaView::saveState(KSharedConfigPtr cfg) -+ void MediaView::saveState(KSharedConfig::Ptr cfg) - { - KConfigGroup g = cfg->group("MediaView"); - g.writeEntry("show_incomplete", show_incomplete->isChecked()); -diff --git a/plugins/mediaplayer/mediaview.h b/plugins/mediaplayer/mediaview.h -index 2b9a7e6..ba2e027 100644 ---- a/plugins/mediaplayer/mediaview.h -+++ b/plugins/mediaplayer/mediaview.h -@@ -25,7 +25,7 @@ - #include - #include - #include --#include -+#include - #include "mediafile.h" - - -@@ -68,8 +68,8 @@ namespace kt - MediaView(MediaModel* model, QWidget* parent); - virtual ~MediaView(); - -- void saveState(KSharedConfigPtr cfg); -- void loadState(KSharedConfigPtr cfg); -+ void saveState(KSharedConfig::Ptr cfg); -+ void loadState(KSharedConfig::Ptr cfg); - - signals: - void doubleClicked(const MediaFileRef& mf); diff --git a/fix-build-with-qt5.6.patch b/fix-build-with-qt5.6.patch new file mode 100644 index 0000000..8c082a7 --- /dev/null +++ b/fix-build-with-qt5.6.patch @@ -0,0 +1,398 @@ +From ce5f7e3de927243c3e9c52eeac66a03f64eaf85d Mon Sep 17 00:00:00 2001 +From: Wolfgang Bauer +Date: Fri, 1 Sep 2017 14:33:56 +0200 +Subject: [PATCH] Lower minimum Qt version to 5.5.0 + +As qAsConst() is new in Qt 5.7.0, define it where needed to make +ktorrent compile with lower Qt versions too. +--- + CMakeLists.txt | 2 +- + ktmagnetdownloader/magnettest.cpp | 8 ++++++++ + ktorrent/core.cpp | 8 ++++++++ + ktorrent/trayicon.cpp | 8 ++++++++ + ktorrent/view/viewmodel.h | 9 +++++++++ + libktcore/groups/groupmanager.cpp | 9 +++++++++ + libktcore/gui/tabbarwidget.cpp | 9 +++++++++ + libktcore/interfaces/torrentactivityinterface.cpp | 9 +++++++++ + libktcore/torrent/magnetmanager.cpp | 9 +++++++++ + libktcore/torrent/queuemanager.cpp | 8 ++++++++ + libktcore/torrent/torrentfilelistmodel.cpp | 9 +++++++++ + libktcore/torrent/torrentfiletreemodel.cpp | 9 +++++++++ + plugins/bwscheduler/schedule.h | 9 +++++++++ + plugins/infowidget/trackermodel.cpp | 9 +++++++++ + plugins/mediaplayer/playlist.cpp | 8 ++++++++ + plugins/search/searchactivity.cpp | 8 ++++++++ + plugins/search/searchenginelist.cpp | 9 +++++++++ + plugins/shutdown/shutdownruleset.cpp | 8 ++++++++ + plugins/upnp/routermodel.cpp | 9 +++++++++ + 19 files changed, 156 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 87428597..a5dc007a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1,7 +1,7 @@ + cmake_minimum_required(VERSION 2.8.12) + project(KTORRENT) + +-set (QT_MIN_VERSION "5.7.0") ++set (QT_MIN_VERSION "5.5.0") + set (KF5_MIN_VERSION "5.15") + + find_package(ECM REQUIRED NO_MODULE) +diff --git a/ktmagnetdownloader/magnettest.cpp b/ktmagnetdownloader/magnettest.cpp +index 7ad15e43..378e3714 100644 +--- a/ktmagnetdownloader/magnettest.cpp ++++ b/ktmagnetdownloader/magnettest.cpp +@@ -38,6 +38,14 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + using namespace kt; + using namespace bt; +diff --git a/ktorrent/core.cpp b/ktorrent/core.cpp +index c8b497da..da740e17 100644 +--- a/ktorrent/core.cpp ++++ b/ktorrent/core.cpp +@@ -62,6 +62,14 @@ + #include "gui.h" + #include "powermanagementinhibit_interface.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + using namespace bt; + +diff --git a/ktorrent/trayicon.cpp b/ktorrent/trayicon.cpp +index a0b9f6ed..fb723268 100644 +--- a/ktorrent/trayicon.cpp ++++ b/ktorrent/trayicon.cpp +@@ -42,6 +42,14 @@ + #include "core.h" + #include "gui.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + using namespace bt; + +diff --git a/ktorrent/view/viewmodel.h b/ktorrent/view/viewmodel.h +index 11217508..b1df54f5 100644 +--- a/ktorrent/view/viewmodel.h ++++ b/ktorrent/view/viewmodel.h +@@ -26,6 +26,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + namespace kt + { + class View; +diff --git a/libktcore/groups/groupmanager.cpp b/libktcore/groups/groupmanager.cpp +index 57ff90a4..902a8e68 100644 +--- a/libktcore/groups/groupmanager.cpp ++++ b/libktcore/groups/groupmanager.cpp +@@ -37,6 +37,15 @@ + #include "ungroupedgroup.h" + #include "functiongroup.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + using namespace bt; + + namespace kt +diff --git a/libktcore/gui/tabbarwidget.cpp b/libktcore/gui/tabbarwidget.cpp +index 8bece605..9a9f6e90 100644 +--- a/libktcore/gui/tabbarwidget.cpp ++++ b/libktcore/gui/tabbarwidget.cpp +@@ -28,6 +28,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + namespace kt + { + +diff --git a/libktcore/interfaces/torrentactivityinterface.cpp b/libktcore/interfaces/torrentactivityinterface.cpp +index 4532761f..063497c3 100644 +--- a/libktcore/interfaces/torrentactivityinterface.cpp ++++ b/libktcore/interfaces/torrentactivityinterface.cpp +@@ -20,6 +20,15 @@ + + #include "torrentactivityinterface.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + namespace kt + { + TorrentActivityInterface::TorrentActivityInterface(const QString& name, const QString& icon, QWidget* parent) +diff --git a/libktcore/torrent/magnetmanager.cpp b/libktcore/torrent/magnetmanager.cpp +index 838959bb..4684c841 100644 +--- a/libktcore/torrent/magnetmanager.cpp ++++ b/libktcore/torrent/magnetmanager.cpp +@@ -29,6 +29,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + using namespace bt; + + namespace kt { +diff --git a/libktcore/torrent/queuemanager.cpp b/libktcore/torrent/queuemanager.cpp +index 0b805ef6..c930221d 100644 +--- a/libktcore/torrent/queuemanager.cpp ++++ b/libktcore/torrent/queuemanager.cpp +@@ -42,6 +42,14 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + using namespace bt; + +diff --git a/libktcore/torrent/torrentfilelistmodel.cpp b/libktcore/torrent/torrentfilelistmodel.cpp +index 00b8436f..082971e4 100644 +--- a/libktcore/torrent/torrentfilelistmodel.cpp ++++ b/libktcore/torrent/torrentfilelistmodel.cpp +@@ -32,6 +32,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + using namespace bt; + + namespace kt +diff --git a/libktcore/torrent/torrentfiletreemodel.cpp b/libktcore/torrent/torrentfiletreemodel.cpp +index 35cf59f4..d6ea23b1 100644 +--- a/libktcore/torrent/torrentfiletreemodel.cpp ++++ b/libktcore/torrent/torrentfiletreemodel.cpp +@@ -38,6 +38,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + using namespace bt; + + namespace kt +diff --git a/plugins/bwscheduler/schedule.h b/plugins/bwscheduler/schedule.h +index 4a630fff..07d95f47 100644 +--- a/plugins/bwscheduler/schedule.h ++++ b/plugins/bwscheduler/schedule.h +@@ -26,6 +26,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + namespace bt + { + class BDictNode; +diff --git a/plugins/infowidget/trackermodel.cpp b/plugins/infowidget/trackermodel.cpp +index a94e0e31..80647128 100644 +--- a/plugins/infowidget/trackermodel.cpp ++++ b/plugins/infowidget/trackermodel.cpp +@@ -28,6 +28,15 @@ + #include + #include + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + namespace kt + { + +diff --git a/plugins/mediaplayer/playlist.cpp b/plugins/mediaplayer/playlist.cpp +index ff277a4e..289c8fe7 100644 +--- a/plugins/mediaplayer/playlist.cpp ++++ b/plugins/mediaplayer/playlist.cpp +@@ -37,6 +37,14 @@ + #include + #include "mediaplayer.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + using namespace bt; + +diff --git a/plugins/search/searchactivity.cpp b/plugins/search/searchactivity.cpp +index 196e781e..679f9500 100644 +--- a/plugins/search/searchactivity.cpp ++++ b/plugins/search/searchactivity.cpp +@@ -45,6 +45,14 @@ + #include + #include "searchtoolbar.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + namespace kt + { +diff --git a/plugins/search/searchenginelist.cpp b/plugins/search/searchenginelist.cpp +index 0d715ed0..766404e0 100644 +--- a/plugins/search/searchenginelist.cpp ++++ b/plugins/search/searchenginelist.cpp +@@ -35,6 +35,15 @@ + #include "searchenginelist.h" + #include "opensearchdownloadjob.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + using namespace bt; + + namespace kt +diff --git a/plugins/shutdown/shutdownruleset.cpp b/plugins/shutdown/shutdownruleset.cpp +index ce728fb3..b3774bd6 100644 +--- a/plugins/shutdown/shutdownruleset.cpp ++++ b/plugins/shutdown/shutdownruleset.cpp +@@ -31,6 +31,14 @@ + #include + #include "shutdownruleset.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif + + using namespace bt; + +diff --git a/plugins/upnp/routermodel.cpp b/plugins/upnp/routermodel.cpp +index 464e2f14..7167f3d4 100644 +--- a/plugins/upnp/routermodel.cpp ++++ b/plugins/upnp/routermodel.cpp +@@ -27,6 +27,15 @@ + #include + #include "routermodel.h" + ++#if QT_VERSION < QT_VERSION_CHECK(5, 7, 0) ++// this adds const to non-const objects (like std::as_const) ++template ++Q_DECL_CONSTEXPR typename std::add_const::type &qAsConst(T &t) Q_DECL_NOTHROW { return t; } ++// prevent rvalue arguments: ++template ++void qAsConst(const T &&) Q_DECL_EQ_DELETE; ++#endif ++ + using namespace bt; + + namespace kt +-- +2.13.5 + diff --git a/fix-crash-when-loading-bandwidth-scheduler-plugin.patch b/fix-crash-when-loading-bandwidth-scheduler-plugin.patch deleted file mode 100644 index 3285dfc..0000000 --- a/fix-crash-when-loading-bandwidth-scheduler-plugin.patch +++ /dev/null @@ -1,57 +0,0 @@ -From f0d807626ff412be8521ee4ec337501df9e328c3 Mon Sep 17 00:00:00 2001 -From: "Martin T. H. Sandsmark" -Date: Mon, 4 Jul 2016 02:25:30 +0200 -Subject: Fix crash when loading bandwidth scheduler plugin - ---- - ktorrent/main.cpp | 4 ++++ - plugins/bwscheduler/weekscene.cpp | 4 ++-- - 2 files changed, 6 insertions(+), 2 deletions(-) - -diff --git a/ktorrent/main.cpp b/ktorrent/main.cpp -index a340e9a..03aa646 100644 ---- a/ktorrent/main.cpp -+++ b/ktorrent/main.cpp -@@ -36,6 +36,7 @@ - #include - #include - #include -+#include - #include - #include - #include -@@ -183,6 +184,9 @@ int main(int argc, char** argv) - parser.process(app); - about.processCommandLine(&parser); - -+ // Ensure that this is set up before plugins call it -+ KLocale::global(); -+ - const KDBusService dbusService(KDBusService::Unique); - - #if 0 //ndef Q_WS_WIN -diff --git a/plugins/bwscheduler/weekscene.cpp b/plugins/bwscheduler/weekscene.cpp -index de8a2f6..523e242 100644 ---- a/plugins/bwscheduler/weekscene.cpp -+++ b/plugins/bwscheduler/weekscene.cpp -@@ -58,7 +58,7 @@ namespace kt - - qreal LongestDayWidth(const QFontMetricsF& fm) - { -- const KCalendarSystem* cal = KGlobal::locale()->calendar(); -+ const KCalendarSystem* cal = KLocale::global()->calendar(); - qreal wd = 0; - for (int i = 1; i <= 7; i++) - { -@@ -93,7 +93,7 @@ namespace kt - - void WeekScene::addCalendar() - { -- const KCalendarSystem* cal = KGlobal::locale()->calendar(); -+ const KCalendarSystem* cal = KLocale::global()->calendar(); - - QGraphicsTextItem* tmp = addText("Dinges"); - QFontMetricsF fm(tmp->font()); --- -cgit v0.11.2 - diff --git a/fix-crashes-in-bwscheduler-plugin.patch b/fix-crashes-in-bwscheduler-plugin.patch deleted file mode 100644 index eaaa71d..0000000 --- a/fix-crashes-in-bwscheduler-plugin.patch +++ /dev/null @@ -1,57 +0,0 @@ -From 9779820c422d6fe395c2aac5eaec49ed003577da Mon Sep 17 00:00:00 2001 -From: "Martin T. H. Sandsmark" -Date: Mon, 4 Jul 2016 02:32:52 +0200 -Subject: Fix crashes in scheduler plugin - ---- - plugins/bwscheduler/edititemdlg.cpp | 4 ++-- - plugins/bwscheduler/weekdaymodel.cpp | 4 ++-- - 2 files changed, 4 insertions(+), 4 deletions(-) - -diff --git a/plugins/bwscheduler/edititemdlg.cpp b/plugins/bwscheduler/edititemdlg.cpp -index 0e8baf3..fe9cd82 100644 ---- a/plugins/bwscheduler/edititemdlg.cpp -+++ b/plugins/bwscheduler/edititemdlg.cpp -@@ -18,7 +18,7 @@ - * Free Software Foundation, Inc., * - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - ***************************************************************************/ --#include -+#include - #include - #include - #include "edititemdlg.h" -@@ -37,7 +37,7 @@ namespace kt - connect(m_suspended, SIGNAL(toggled(bool)), this, SLOT(suspendedChanged(bool))); - connect(m_screensaver_limits, SIGNAL(toggled(bool)), this, SLOT(screensaverLimitsToggled(bool))); - -- const KCalendarSystem* cal = KGlobal::locale()->calendar(); -+ const KCalendarSystem* cal = KLocale::global()->calendar(); - for (int i = 1; i <= 7; i++) - { - m_start_day->addItem(cal->weekDayName(i)); -diff --git a/plugins/bwscheduler/weekdaymodel.cpp b/plugins/bwscheduler/weekdaymodel.cpp -index 5df59e3..3299006 100644 ---- a/plugins/bwscheduler/weekdaymodel.cpp -+++ b/plugins/bwscheduler/weekdaymodel.cpp -@@ -20,7 +20,7 @@ - ***************************************************************************/ - #include "weekdaymodel.h" - --#include -+#include - #include - - namespace kt -@@ -54,7 +54,7 @@ namespace kt - - if (role == Qt::DisplayRole) - { -- const KCalendarSystem* cal = KGlobal::locale()->calendar(); -+ const KCalendarSystem* cal = KLocale::global()->calendar(); - return cal->weekDayName(index.row() + 1); - } - else if (role == Qt::CheckStateRole) --- -cgit v0.11.2 - diff --git a/initial-preference.diff b/initial-preference.diff index 2e8566c..0d2090c 100644 --- a/initial-preference.diff +++ b/initial-preference.diff @@ -6,5 +6,5 @@ MimeType=application/x-bittorrent;application/x-torrent;x-scheme-handler/magnet; +InitialPreference=5 X-DBUS-StartupType=Unique - X-DBUS-ServiceName=org.ktorrent.ktorrent - Comment=A BitTorrent program for KDE + X-DBUS-ServiceName=org.kde.ktorrent + Comment=A BitTorrent program by KDE diff --git a/ktorrent-5.0.1.tar.xz b/ktorrent-5.0.1.tar.xz deleted file mode 100644 index 5f5bf99..0000000 --- a/ktorrent-5.0.1.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:d00feeca5dcc6a76a039d67dbe91a2d5a5e1da0f5e0bbd8da2c156d9c44879e5 -size 2152908 diff --git a/ktorrent-5.1.0.tar.xz b/ktorrent-5.1.0.tar.xz new file mode 100644 index 0000000..410e62d --- /dev/null +++ b/ktorrent-5.1.0.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3c57882f78006dcec3c5fb243479e995cc541e51e6acded5bf98a09900c486a3 +size 2046916 diff --git a/ktorrent.1 b/ktorrent.1 index 133fc51..dc6f78b 100644 --- a/ktorrent.1 +++ b/ktorrent.1 @@ -1,134 +1,32 @@ -.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.40.4. -.TH KTORRENT "1" "November 2011" "ktorrent " "User Commands" +.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.43.3. +.TH KTORRENT "1" "September 2017" "ktorrent 5.1.0" "User Commands" .SH NAME -ktorrent \- Bittorrent client for KDE +ktorrent \- manual page for ktorrent 5.1.0 .SH SYNOPSIS .B ktorrent -[\fIQt-options\fR] [\fIKDE-options\fR] [\fIUrl\fR] +[\fIoptions\fR] .SH DESCRIPTION -Bittorrent client for KDE -.SS "Generic options:" -.TP -\fB\-\-help\fR -Show help about options -.TP -\fB\-\-help\-qt\fR -Show Qt specific options -.TP -\fB\-\-help\-kde\fR -Show KDE specific options -.TP -\fB\-\-help\-all\fR -Show all options -.TP -\fB\-\-author\fR -Show author information +Bittorrent client by KDE +.SH OPTIONS .TP \fB\-v\fR, \fB\-\-version\fR -Show version information +Displays version information. +.TP +\fB\-h\fR, \fB\-\-help\fR +Displays this help. +.TP +\fB\-\-author\fR +Show author information. .TP \fB\-\-license\fR -Show license information +Show license information. .TP -\fB\-\-\fR -End of options -.SS "Qt options:" -.TP -\fB\-\-display\fR -Use the X\-server display 'displayname' -.TP -\fB\-\-session\fR -Restore the application for the given 'sessionId' -.TP -\fB\-\-cmap\fR -Causes the application to install a private color -map on an 8\-bit display -.TP -\fB\-\-ncols\fR -Limits the number of colors allocated in the color -cube on an 8\-bit display, if the application is -using the QApplication::ManyColor color -specification -.TP -\fB\-\-nograb\fR -tells Qt to never grab the mouse or the keyboard -.TP -\fB\-\-dograb\fR -running under a debugger can cause an implicit -\fB\-nograb\fR, use \fB\-dograb\fR to override -.TP -\fB\-\-sync\fR -switches to synchronous mode for debugging -.TP -\fB\-\-fn\fR, \fB\-\-font\fR -defines the application font -.TP -\fB\-\-bg\fR, \fB\-\-background\fR sets the default background color and an -application palette (light and dark shades are -calculated) -.HP -\fB\-\-fg\fR, \fB\-\-foreground\fR sets the default foreground color -.TP -\fB\-\-btn\fR, \fB\-\-button\fR -sets the default button color -.TP -\fB\-\-name\fR -sets the application name -.TP -\fB\-\-title\fR -sets the application title (caption) -.TP -\fB\-\-visual\fR TrueColor -forces the application to use a TrueColor visual on -an 8\-bit display -.TP -\fB\-\-inputstyle\fR <inputstyle> sets XIM (X Input Method) input style. Possible -values are onthespot, overthespot, offthespot and -root -.TP -\fB\-\-im\fR <XIM server> -set XIM server -.TP -\fB\-\-noxim\fR -disable XIM -.TP -\fB\-\-reverse\fR -mirrors the whole layout of widgets -.TP -\fB\-\-stylesheet\fR <file.qss> -applies the Qt stylesheet to the application widgets -.HP -\fB\-\-graphicssystem\fR <system> use a different graphics system instead of the default one, options are raster and opengl (experimental) -.SS "KDE options:" -.TP -\fB\-\-caption\fR <caption> -Use 'caption' as name in the titlebar -.TP -\fB\-\-icon\fR <icon> -Use 'icon' as the application icon -.TP -\fB\-\-config\fR <filename> -Use alternative configuration file -.TP -\fB\-\-nocrashhandler\fR -Disable crash handler, to get core dumps -.TP -\fB\-\-waitforwm\fR -Waits for a WM_NET compatible windowmanager -.TP -\fB\-\-style\fR <style> -sets the application GUI style -.TP -\fB\-\-geometry\fR <geometry> -sets the client geometry of the main widget \- see man X for the argument format (usually WidthxHeight+XPos+YPos) -.TP -\fB\-\-nofork\fR -Do not run in the background. -.SS "Arguments:" -.TP -Url -Document to open -.SH OPTIONS +\fB\-\-desktopfile\fR <file name> +The base file name of the desktop entry for this +application. .TP \fB\-\-silent\fR Silently open torrent given on URL +.TP +\fB\-\-\fR+[URL] +Document to open diff --git a/ktorrent.changes b/ktorrent.changes index ce8a97e..807bd49 100644 --- a/ktorrent.changes +++ b/ktorrent.changes @@ -1,3 +1,22 @@ +------------------------------------------------------------------- +Sat Sep 2 09:19:00 UTC 2017 - wbauer@tmo.at + +- Update to version 5.1.0 + * Multimedia, search, scanfolder, ipfilter, stats, scripting, + syndication (rss) plugins are now ported to Qt5. The only + missing bits are webinterface plugin and plasmoid. +- Update build requirements +- Add fix-build-with-qt5.6.patch to make it build with Qt < 5.7.0 +- Use gcc5 on Leap 42, it crashes on startup when built with 4.8.5 +- Update installed man pages +- Drop upstream patches included in this release: + * fix-build-with-newer-kconfig.diff + * fix-crash-when-loading-bandwidth-scheduler-plugin.patch + * fix-crashes-in-bwscheduler-plugin.patch +- Drop openSUSE patches that are no longer necessary: + * remove-links.diff - the corresponding URLs are no longer in the list + * suse-dht-warning.diff - it was broken anyway (boo#1002948) + ------------------------------------------------------------------- Tue May 23 10:55:02 UTC 2017 - wbauer@tmo.at diff --git a/ktorrent.spec b/ktorrent.spec index 750c952..bca297e 100644 --- a/ktorrent.spec +++ b/ktorrent.spec @@ -17,27 +17,19 @@ Name: ktorrent -Version: 5.0.1 +Version: 5.1.0 Release: 0 Summary: KDE BitTorrent Client License: GPL-2.0+ Group: Productivity/Networking/File-Sharing Url: http://ktorrent.org/ -Source0: http://download.kde.org/stable/ktorrent/5.0/%{name}-%{version}.tar.xz +Source0: http://download.kde.org/stable/ktorrent/5.1/%{name}-%{version}.tar.xz Source2: ktorrent.1 Source3: ktupnptest.1 -# PATCH-FIX-OPENSUSE remove-links.diff adrian@suse.de -- Remove links to some search engine with maybe legal problems -Patch0: remove-links.diff -# PATCH-FIX-OPENSUSE suse-dht-warning.diff wstephenson@novell.com -- Warning popup for DHT -Patch1: suse-dht-warning.diff # PATCH-FIX-OPENSUSE initial-preference.diff cmorve69@yahoo.es -- InitialPreference to set it as the default torrent downloader -Patch2: initial-preference.diff -# PATCH-FIX-UPSTREAM fix-build-with-newer-kconfig.diff -- Fix build with newer KConfig -Patch3: fix-build-with-newer-kconfig.diff -# PATCH-FIX-UPSTREAM fix-crash-when-loading-bandwidth-scheduler-plugin.patch -Patch4: fix-crash-when-loading-bandwidth-scheduler-plugin.patch -# PATCH-FIX-UPSTREAM fix-crashes-in-bwscheduler-plugin.patch -Patch5: fix-crashes-in-bwscheduler-plugin.patch +Patch0: initial-preference.diff +# PATCH-FIX-OPENSUSE fix-build-with-qt5.6.patch -- make it build with Qt < 5.7.0 (i.e. on Leap 42.x) +Patch1: fix-build-with-qt5.6.patch %if 0%{?suse_version} > 1325 BuildRequires: libboost_headers-devel %else @@ -45,39 +37,53 @@ BuildRequires: boost-devel %endif BuildRequires: extra-cmake-modules BuildRequires: fdupes -BuildRequires: gmp-devel +BuildRequires: karchive-devel BuildRequires: kcmutils-devel +BuildRequires: kcompletion-devel BuildRequires: kconfig-devel +BuildRequires: kconfigwidgets-devel BuildRequires: kcoreaddons-devel BuildRequires: kcrash-devel BuildRequires: kdbusaddons-devel -BuildRequires: kdelibs4support-devel BuildRequires: kdewebkit-devel +BuildRequires: kdnssd-framework-devel BuildRequires: kdoctools-devel BuildRequires: ki18n-devel +BuildRequires: kiconthemes-devel BuildRequires: kio-devel +BuildRequires: kitemviews-devel BuildRequires: knotifications-devel BuildRequires: knotifyconfig-devel +BuildRequires: kparts-devel BuildRequires: kplotting-devel BuildRequires: kross-devel +BuildRequires: kservice-devel +BuildRequires: ktextwidgets-devel +BuildRequires: kwidgetsaddons-devel +BuildRequires: kwindowsystem-devel BuildRequires: kxmlgui-devel -BuildRequires: libktorrent-devel >= 2.0 -BuildRequires: libqca-qt5-devel +BuildRequires: libktorrent-devel >= 2.1 BuildRequires: phonon4qt5-devel BuildRequires: plasma5-workspace-devel BuildRequires: solid-devel -BuildRequires: sonnet-devel +BuildRequires: syndication-devel BuildRequires: update-desktop-files BuildRequires: pkgconfig(Qt5Core) BuildRequires: pkgconfig(Qt5DBus) +BuildRequires: pkgconfig(Qt5Network) BuildRequires: pkgconfig(Qt5Script) BuildRequires: pkgconfig(Qt5Widgets) BuildRequires: pkgconfig(taglib) +%if 0%{?suse_version} < 1330 +BuildRequires: gcc5 +BuildRequires: gcc5-c++ +#!BuildIgnore: libgcc_s1 +%endif Recommends: %{name}-lang = %{version} BuildRoot: %{_tmppath}/%{name}-%{version}-build %description -KTorrent is a bittorrent application for KDE which allows you to download files +KTorrent is a BitTorrent application by KDE which allows you to download files using the BitTorrent protocol. It enables you to run multiple torrents at the same time and comes with extended features to make it a full-featured client for BitTorrent. @@ -86,16 +92,16 @@ for BitTorrent. %prep %setup -q %patch0 -%if ! 0%{?packman_bs} -%patch1 +%if 0%{?suse_version} < 1330 +%patch1 -p1 %endif -%patch2 -%patch3 -p1 -%patch4 -p1 -%patch5 -p1 %build +%if 0%{?suse_version} < 1330 +%cmake_kf5 -d build -- -DCMAKE_C_COMPILER=gcc-5 -DCMAKE_CXX_COMPILER=g++-5 +%else %cmake_kf5 -d build +%endif %make_jobs %install @@ -131,6 +137,8 @@ fi %doc %{_mandir}/man1/ktorrent.1%{ext_man} %doc %{_mandir}/man1/ktupnptest.1%{ext_man} %_bindir/ktorrent +%_bindir/ktmagnetdownloader +%_bindir/ktupnptest %_libdir/libktcore.so.* %_kf5_plugindir/ %_kf5_applicationsdir/org.kde.ktorrent.desktop @@ -139,6 +147,9 @@ fi %_kf5_notifydir/ktorrent.notifyrc %_kf5_kxmlguidir/ktorrent/ %_kf5_htmldir/en/ktorrent/ +%_kf5_sharedir/ktorrent/ +%dir %_kf5_appstreamdir +%_kf5_appstreamdir/org.kde.ktorrent.appdata.xml %files lang -f %{name}.lang %defattr(-,root,root,-) diff --git a/ktupnptest.1 b/ktupnptest.1 index c1664f6..cc0cb35 100644 --- a/ktupnptest.1 +++ b/ktupnptest.1 @@ -1,123 +1,26 @@ -.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.40.4. -.TH KTUPNPTEST "1" "November 2011" "ktupnptest " "User Commands" +.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.43.3. +.TH KTUPNP "1" "September 2017" "ktupnp 1.0" "User Commands" .SH NAME -ktupnptest \- KTorrent's UPnP test application +ktupnp \- manual page for ktupnp 1.0 .SH SYNOPSIS .B ktupnptest -[\fIQt-options\fR] [\fIKDE-options\fR] +[\fIoptions\fR] .SH DESCRIPTION KTorrent's UPnP test application -.SS "Generic options:" -.TP -\fB\-\-help\fR -Show help about options -.TP -\fB\-\-help\-qt\fR -Show Qt specific options -.TP -\fB\-\-help\-kde\fR -Show KDE specific options -.TP -\fB\-\-help\-all\fR -Show all options -.TP -\fB\-\-author\fR -Show author information +.SH OPTIONS .TP \fB\-v\fR, \fB\-\-version\fR -Show version information +Displays version information. +.TP +\fB\-h\fR, \fB\-\-help\fR +Displays this help. +.TP +\fB\-\-author\fR +Show author information. .TP \fB\-\-license\fR -Show license information +Show license information. .TP -\fB\-\-\fR -End of options -.SS "Qt options:" -.TP -\fB\-\-display\fR <displayname> -Use the X\-server display 'displayname' -.TP -\fB\-\-session\fR <sessionId> -Restore the application for the given 'sessionId' -.TP -\fB\-\-cmap\fR -Causes the application to install a private color -map on an 8\-bit display -.TP -\fB\-\-ncols\fR <count> -Limits the number of colors allocated in the color -cube on an 8\-bit display, if the application is -using the QApplication::ManyColor color -specification -.TP -\fB\-\-nograb\fR -tells Qt to never grab the mouse or the keyboard -.TP -\fB\-\-dograb\fR -running under a debugger can cause an implicit -\fB\-nograb\fR, use \fB\-dograb\fR to override -.TP -\fB\-\-sync\fR -switches to synchronous mode for debugging -.TP -\fB\-\-fn\fR, \fB\-\-font\fR <fontname> -defines the application font -.TP -\fB\-\-bg\fR, \fB\-\-background\fR <color> sets the default background color and an -application palette (light and dark shades are -calculated) -.HP -\fB\-\-fg\fR, \fB\-\-foreground\fR <color> sets the default foreground color -.TP -\fB\-\-btn\fR, \fB\-\-button\fR <color> -sets the default button color -.TP -\fB\-\-name\fR <name> -sets the application name -.TP -\fB\-\-title\fR <title> -sets the application title (caption) -.TP -\fB\-\-visual\fR TrueColor -forces the application to use a TrueColor visual on -an 8\-bit display -.TP -\fB\-\-inputstyle\fR <inputstyle> sets XIM (X Input Method) input style. Possible -values are onthespot, overthespot, offthespot and -root -.TP -\fB\-\-im\fR <XIM server> -set XIM server -.TP -\fB\-\-noxim\fR -disable XIM -.TP -\fB\-\-reverse\fR -mirrors the whole layout of widgets -.TP -\fB\-\-stylesheet\fR <file.qss> -applies the Qt stylesheet to the application widgets -.HP -\fB\-\-graphicssystem\fR <system> use a different graphics system instead of the default one, options are raster and opengl (experimental) -.SS "KDE options:" -.TP -\fB\-\-caption\fR <caption> -Use 'caption' as name in the titlebar -.TP -\fB\-\-icon\fR <icon> -Use 'icon' as the application icon -.TP -\fB\-\-config\fR <filename> -Use alternative configuration file -.TP -\fB\-\-nocrashhandler\fR -Disable crash handler, to get core dumps -.TP -\fB\-\-waitforwm\fR -Waits for a WM_NET compatible windowmanager -.TP -\fB\-\-style\fR <style> -sets the application GUI style -.TP -\fB\-\-geometry\fR <geometry> -sets the client geometry of the main widget \- see man X for the argument format (usually WidthxHeight+XPos+YPos) +\fB\-\-desktopfile\fR <file name> +The base file name of the desktop entry for this +application. diff --git a/remove-links.diff b/remove-links.diff deleted file mode 100644 index 8951710..0000000 --- a/remove-links.diff +++ /dev/null @@ -1,18 +0,0 @@ -diff -urNB ktorrent-5.0/plugins/search/searchenginelist.cpp new/plugins/search/searchenginelist.cpp ---- plugins/search/searchenginelist.cpp 2016-03-30 11:25:13.000000000 +0200 -+++ plugins/search/searchenginelist.cpp 2016-04-16 18:46:41.622344264 +0200 -@@ -41,10 +41,13 @@ - default_opensearch_urls << QUrl(QLatin1String("http://www.torrentz.com")) << QUrl(QLatin1String("http://isohunt.com")); - default_urls << QUrl(QLatin1String("http://www.ktorrents.com")) - << QUrl(QLatin1String("http://www.bittorrent.com")) -+#if 0 - << QUrl(QLatin1String("http://www.mininova.org")) - << QUrl(QLatin1String("http://thepiratebay.org")) - << QUrl(QLatin1String("http://www.bitenova.org")) -- << QUrl(QLatin1String("http://btjunkie.org")); -+ << QUrl(QLatin1String("http://btjunkie.org")) -+#endif -+ ; - } - - diff --git a/suse-dht-warning.diff b/suse-dht-warning.diff deleted file mode 100644 index 598eb75..0000000 --- a/suse-dht-warning.diff +++ /dev/null @@ -1,86 +0,0 @@ -diff -urNB ktorrent-5.0/CMakeLists.txt new/CMakeLists.txt ---- CMakeLists.txt 2016-04-15 00:30:28.000000000 +0200 -+++ CMakeLists.txt 2016-04-16 13:52:36.168059210 +0200 -@@ -16,7 +16,7 @@ - - find_package(Qt5 ${QT_MIN_VERSION} CONFIG REQUIRED Core DBus Widgets Script) - --find_package(KF5 5.15 REQUIRED I18n KIO XmlGui Notifications NotifyConfig Solid Config CoreAddons DocTools Kross KCMUtils Sonnet DBusAddons Crash Archive KDELibs4Support) -+find_package(KF5 5.15 REQUIRED I18n KIO XmlGui Notifications NotifyConfig Solid Config ConfigWidgets CoreAddons DocTools Kross KCMUtils Sonnet DBusAddons Crash Archive KDELibs4Support) - - find_package(LibKTorrent 1.9.50 CONFIG REQUIRED) - find_package(Boost REQUIRED) -diff -urNB ktorrent-5.0/ktorrent/CMakeLists.txt new/ktorrent/CMakeLists.txt ---- ktorrent/CMakeLists.txt 2016-03-30 11:25:13.000000000 +0200 -+++ ktorrent/CMakeLists.txt 2016-04-16 13:53:51.520453793 +0200 -@@ -88,6 +88,7 @@ - KF5::Parts - KF5::DBusAddons - KF5::KDELibs4Support -+ KF5::ConfigWidgets - ) - - install(TARGETS ktorrent_app ${INSTALL_TARGETS_DEFAULT_ARGS}) -@@ -95,6 +96,7 @@ - install(FILES ktorrentui.rc DESTINATION ${KXMLGUI_INSTALL_DIR}/ktorrent ) - install(FILES kttorrentactivityui.rc DESTINATION ${KXMLGUI_INSTALL_DIR}/ktorrent ) - install(FILES ktorrent.notifyrc DESTINATION ${KNOTIFYRC_INSTALL_DIR} ) -+install(FILES dhttip DESTINATION ${KXMLGUI_INSTALL_DIR}/ktorrent ) - - - add_subdirectory(icons) -diff -urNB ktorrent-5.0/ktorrent/dhttip new/ktorrent/dhttip ---- ktorrent/dhttip 1970-01-01 01:00:00.000000000 +0100 -+++ ktorrent/dhttip 2016-04-16 13:54:19.072598069 +0200 -@@ -0,0 +1,10 @@ -+<tip category="Ktorrent"> -+<html> -+<p> -+Please respect the rights of copyright holders. -+</p> -+<p> -+Free Software also depends upon the principle of copyright. -+</p> -+</html> -+</tip> -diff -urNB ktorrent-5.0/ktorrent/gui.cpp new/ktorrent/gui.cpp ---- ktorrent/gui.cpp 2016-03-30 11:25:13.000000000 +0200 -+++ ktorrent/gui.cpp 2016-04-16 18:15:12.284449587 +0200 -@@ -37,6 +37,7 @@ - #include <krecentdirs.h> - #include <kxmlguifactory.h> - #include <KNotifyConfigWidget> -+#include <KTipDialog> - #include <kio/jobclasses.h> - #include <kio/jobuidelegate.h> - #include <kparts/partmanager.h> -@@ -122,6 +123,8 @@ - //markk.update(); - updateActions(); - core->startUpdateTimer(); -+ -+ QTimer::singleShot(0, this, SLOT(showDhtTip())); - } - - GUI::~GUI() -@@ -571,4 +574,9 @@ - return torrent_activity; - } - -+ void GUI::showDhtTip() -+ { -+ KTipDialog::showTip(this, "ktorrent/dhttip"); -+ } -+ - } -diff -urNB ktorrent-5.0/ktorrent/gui.h new/ktorrent/gui.h ---- ktorrent/gui.h 2016-03-30 11:25:13.000000000 +0200 -+++ ktorrent/gui.h 2016-04-16 18:16:22.112815265 +0200 -@@ -112,6 +112,7 @@ - void configureNotifications(); - void activePartChanged(KParts::Part* p); - void quit(); -+ void showDhtTip(); - - private: - void setupActions();