diff --git a/package/libtorrent-rasterbar/0001-fix-more-c-17-that-made-it-in.patch b/package/libtorrent-rasterbar/0001-fix-more-c-17-that-made-it-in.patch new file mode 100644 index 0000000000..afce75b9ff --- /dev/null +++ b/package/libtorrent-rasterbar/0001-fix-more-c-17-that-made-it-in.patch @@ -0,0 +1,53 @@ +From 2638789b7048e17aba7cc8674305f36bd349c795 Mon Sep 17 00:00:00 2001 +From: Bernd Kuhls +Date: Mon, 14 Sep 2026 17:31:24 +0200 +Subject: [PATCH] fix more c++17 that made it in +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Patch was inspired by https://github.com/arvidn/libtorrent/pull/4805 +and fixes a build error with gcc-9.3.0 + +buildroot/output/build/libtorrent-rasterbar-2.1.1/src/torrent_info.cpp:855:16: + error: function ‘libtorrent::torrent_info& libtorrent::torrent_info::operator=(libtorrent::torrent_info&&)’ + defaulted on its redeclaration with an exception-specification that + differs from the implicit exception-specification ‘’ + +Upstream: https://github.com/arvidn/libtorrent/pull/8869 + +Signed-off-by: Bernd Kuhls +--- + include/libtorrent/torrent_info.hpp | 2 +- + src/torrent_info.cpp | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/include/libtorrent/torrent_info.hpp b/include/libtorrent/torrent_info.hpp +index 8843179a2..add61c2d7 100644 +--- a/include/libtorrent/torrent_info.hpp ++++ b/include/libtorrent/torrent_info.hpp +@@ -213,7 +213,7 @@ TORRENT_VERSION_NAMESPACE_4 + + // hidden + torrent_info& operator=(torrent_info const&) = delete; +- torrent_info& operator=(torrent_info&&) noexcept; ++ torrent_info& operator=(torrent_info&&); + + // The file_storage object contains the information on how to map the + // pieces to files. It is separated from the torrent_info object as the +diff --git a/src/torrent_info.cpp b/src/torrent_info.cpp +index 0a4b90b04..6fe584c39 100644 +--- a/src/torrent_info.cpp ++++ b/src/torrent_info.cpp +@@ -856,7 +856,7 @@ namespace { + TORRENT_VERSION_NAMESPACE_4 + + torrent_info::torrent_info(torrent_info const&) = default; +- torrent_info& torrent_info::operator=(torrent_info&&) noexcept = default; ++ torrent_info& torrent_info::operator=(torrent_info&&) = default; + + #if TORRENT_ABI_VERSION < 4 + void torrent_info::remap_files(file_storage const& f) +-- +2.47.3 + diff --git a/package/libtorrent-rasterbar/Config.in b/package/libtorrent-rasterbar/Config.in index 459edc1be5..d78f9ac206 100644 --- a/package/libtorrent-rasterbar/Config.in +++ b/package/libtorrent-rasterbar/Config.in @@ -1,8 +1,9 @@ -comment "libtorrent-rasterbar needs a toolchain w/ C++, threads, wchar, gcc >= 4.9" +comment "libtorrent-rasterbar needs a toolchain w/ C++, threads, wchar, gcc >= 8" depends on BR2_TOOLCHAIN_SUPPORTS_VARIADIC_MI_THUNK depends on !BR2_TOOLCHAIN_HAS_GCC_BUG_64735 + depends on BR2_USE_MMU depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \ - !BR2_USE_WCHAR || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 + !BR2_USE_WCHAR || !BR2_TOOLCHAIN_GCC_AT_LEAST_8 comment "libtorrent-rasterbar needs exception_ptr" depends on BR2_TOOLCHAIN_SUPPORTS_VARIADIC_MI_THUNK @@ -11,9 +12,10 @@ comment "libtorrent-rasterbar needs exception_ptr" config BR2_PACKAGE_LIBTORRENT_RASTERBAR bool "libtorrent-rasterbar" depends on BR2_INSTALL_LIBSTDCPP # boost - depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # C++11 + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_8 # string_view depends on BR2_TOOLCHAIN_HAS_THREADS # boost depends on BR2_TOOLCHAIN_SUPPORTS_VARIADIC_MI_THUNK + depends on BR2_USE_MMU # madvise() depends on BR2_USE_WCHAR # boost depends on !BR2_TOOLCHAIN_HAS_GCC_BUG_64735 # exception_ptr select BR2_PACKAGE_BOOST diff --git a/package/libtorrent-rasterbar/libtorrent-rasterbar.hash b/package/libtorrent-rasterbar/libtorrent-rasterbar.hash index 6b6175d9de..19f11665e6 100644 --- a/package/libtorrent-rasterbar/libtorrent-rasterbar.hash +++ b/package/libtorrent-rasterbar/libtorrent-rasterbar.hash @@ -1,3 +1,4 @@ +# From https://github.com/arvidn/libtorrent/releases/tag/v2.1.1 +sha256 0f163516ecef2e3331500266751de3098835a3c3ae0c2290448046c632bc0e93 libtorrent-rasterbar-2.1.1.tar.gz # Locally calculated -sha256 ccbf8e8c21dc81635de95166b498922b4725f9725a23b2cfe2a6b2fead6fb9fc libtorrent-rasterbar-1.2.20.tar.gz -sha256 f3a5dd1558cce616b12edad521427ec8976ce2bb0af33f7f359cfa648bf55ad8 COPYING +sha256 f4b492afbde73d2f4e051050a619622876a13b77e7b8b6ea3ec2868a6929b31b COPYING diff --git a/package/libtorrent-rasterbar/libtorrent-rasterbar.mk b/package/libtorrent-rasterbar/libtorrent-rasterbar.mk index 2cc24c487a..d71907b1be 100644 --- a/package/libtorrent-rasterbar/libtorrent-rasterbar.mk +++ b/package/libtorrent-rasterbar/libtorrent-rasterbar.mk @@ -4,7 +4,7 @@ # ################################################################################ -LIBTORRENT_RASTERBAR_VERSION = 1.2.20 +LIBTORRENT_RASTERBAR_VERSION = 2.1.1 LIBTORRENT_RASTERBAR_SITE = \ https://github.com/arvidn/libtorrent/releases/download/v$(LIBTORRENT_RASTERBAR_VERSION) LIBTORRENT_RASTERBAR_LICENSE = BSD-3-Clause @@ -13,10 +13,7 @@ LIBTORRENT_RASTERBAR_CPE_ID_VENDOR = libtorrent LIBTORRENT_RASTERBAR_CPE_ID_PRODUCT = libtorrent LIBTORRENT_RASTERBAR_DEPENDENCIES = host-pkgconf boost LIBTORRENT_RASTERBAR_INSTALL_STAGING = YES -LIBTORRENT_RASTERBAR_CONF_OPTS = \ - --with-boost-libdir=$(STAGING_DIR)/usr/lib \ - --disable-invariant-checks -LIBTORRENT_RASTERBAR_CXXFLAGS = $(TARGET_CXXFLAGS) -std=c++11 +LIBTORRENT_RASTERBAR_CXXFLAGS = $(TARGET_CXXFLAGS) # Internal error, aborting at dwarf2cfi.c:2802 in connect_traces # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58864 @@ -28,20 +25,13 @@ ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_85180),y) LIBTORRENT_RASTERBAR_CXXFLAGS += -O0 endif -LIBTORRENT_RASTERBAR_CONF_OPTS += CXXFLAGS="$(LIBTORRENT_RASTERBAR_CXXFLAGS)" - -ifeq ($(BR2_ENABLE_LOCALE)$(BR2_PACKAGE_LIBICONV),y) -LIBTORRENT_RASTERBAR_DEPENDENCIES += $(if $(BR2_PACKAGE_LIBICONV),libiconv) -LIBTORRENT_RASTERBAR_CONF_OPTS += --with-libiconv -else -LIBTORRENT_RASTERBAR_CONF_OPTS += --without-libiconv -endif +LIBTORRENT_RASTERBAR_CONF_OPTS += -DCMAKE_CXX_FLAGS="$(LIBTORRENT_RASTERBAR_CXXFLAGS)" ifeq ($(BR2_PACKAGE_OPENSSL),y) LIBTORRENT_RASTERBAR_DEPENDENCIES += openssl -LIBTORRENT_RASTERBAR_CONF_OPTS += --enable-encryption +LIBTORRENT_RASTERBAR_CONF_OPTS += -Dencryption=ON -Dwebtorrent=ON else -LIBTORRENT_RASTERBAR_CONF_OPTS += --disable-encryption +LIBTORRENT_RASTERBAR_CONF_OPTS += -Dencryption=OFF -Dwebtorrent=OFF endif -$(eval $(autotools-package)) +$(eval $(cmake-package))