public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2016-05-03 17:35 Austin English
  0 siblings, 0 replies; 10+ messages in thread
From: Austin English @ 2016-05-03 17:35 UTC (permalink / raw
  To: gentoo-commits

commit:     46c19a04bc452de7101319de04913d533d3f5e30
Author:     Austin English <wizardedit <AT> gentoo <DOT> org>
AuthorDate: Tue May  3 17:18:45 2016 +0000
Commit:     Austin English <wizardedit <AT> gentoo <DOT> org>
CommitDate: Tue May  3 17:21:40 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=46c19a04

net-p2p/amule: use #!/sbin/openrc-run instead of #!/sbin/runscript

Gentoo-Bug: https://bugs.gentoo.org/573846

Package-Manager: portage-2.2.26

 net-p2p/amule/amule-2.3.1-r2.ebuild | 109 ++++++++++++++++++++++++++++++++++++
 net-p2p/amule/files/amuled.initd    |   4 +-
 net-p2p/amule/files/amuleweb.initd  |   4 +-
 3 files changed, 113 insertions(+), 4 deletions(-)

diff --git a/net-p2p/amule/amule-2.3.1-r2.ebuild b/net-p2p/amule/amule-2.3.1-r2.ebuild
new file mode 100644
index 0000000..dceb2cd
--- /dev/null
+++ b/net-p2p/amule/amule-2.3.1-r2.ebuild
@@ -0,0 +1,109 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit wxwidgets user
+
+MY_P=${PN/m/M}-${PV}
+S="${WORKDIR}"/${MY_P}
+
+DESCRIPTION="aMule, the all-platform eMule p2p client"
+HOMEPAGE="http://www.amule.org/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="daemon debug geoip nls remote stats unicode upnp +X"
+
+DEPEND=">=dev-libs/crypto++-5
+	sys-libs/binutils-libs:0=
+	>=sys-libs/zlib-1.2.1
+	>=x11-libs/wxGTK-2.8.12:2.8[X?]
+	stats? ( >=media-libs/gd-2.0.26:=[jpeg] )
+	geoip? ( dev-libs/geoip )
+	upnp? ( >=net-libs/libupnp-1.6.6 )
+	remote? ( >=media-libs/libpng-1.2.0:0=
+	unicode? ( >=media-libs/gd-2.0.26:= ) )
+	!net-p2p/imule"
+RDEPEND="${DEPEND}"
+
+pkg_setup() {
+	if use stats && ! use X; then
+		einfo "Note: You would need both the X and stats USE flags"
+		einfo "to compile aMule Statistics GUI."
+		einfo "I will now compile console versions only."
+	fi
+}
+
+pkg_preinst() {
+	if use daemon || use remote; then
+		enewgroup p2p
+		enewuser p2p -1 -1 /home/p2p p2p
+	fi
+}
+
+src_prepare() {
+	eapply "${FILESDIR}"/${PN}-2.2.6-fallocate.diff
+	# Bug 412371
+	eapply "${FILESDIR}"/${PN}-2.3.1-gcc47.patch
+
+	default
+}
+
+src_configure() {
+	local myconf
+
+	WX_GTK_VER="2.8"
+
+	if use X; then
+		einfo "wxGTK with X support will be used"
+		need-wxwidgets unicode
+	else
+		einfo "wxGTK without X support will be used"
+		need-wxwidgets base-unicode
+	fi
+
+	if use X ; then
+		use stats && myconf="${myconf}
+			--enable-wxcas
+			--enable-alc"
+		use remote && myconf="${myconf}
+			--enable-amule-gui"
+	else
+		myconf="
+			--disable-monolithic
+			--disable-amule-gui
+			--disable-wxcas
+			--disable-alc"
+	fi
+
+	econf \
+		--with-denoise-level=0 \
+		--with-wx-config="${WX_CONFIG}" \
+		--enable-amulecmd \
+		$(use_enable debug) \
+		$(use_enable daemon amule-daemon) \
+		$(use_enable geoip) \
+		$(use_enable nls) \
+		$(use_enable remote webserver) \
+		$(use_enable stats cas) \
+		$(use_enable stats alcc) \
+		$(use_enable upnp) \
+		${myconf}
+}
+
+src_install() {
+	default
+
+	if use daemon; then
+		newconfd "${FILESDIR}"/amuled.confd amuled
+		newinitd "${FILESDIR}"/amuled.initd amuled
+	fi
+	if use remote; then
+		newconfd "${FILESDIR}"/amuleweb.confd amuleweb
+		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
+	fi
+}

diff --git a/net-p2p/amule/files/amuled.initd b/net-p2p/amule/files/amuled.initd
index 082e2ff..1c070e6 100644
--- a/net-p2p/amule/files/amuled.initd
+++ b/net-p2p/amule/files/amuled.initd
@@ -1,5 +1,5 @@
-#!/sbin/runscript
-# Copyright 1999-2005 Gentoo Foundation
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 

diff --git a/net-p2p/amule/files/amuleweb.initd b/net-p2p/amule/files/amuleweb.initd
index 05e7d9f..d091e2a 100644
--- a/net-p2p/amule/files/amuleweb.initd
+++ b/net-p2p/amule/files/amuleweb.initd
@@ -1,5 +1,5 @@
-#!/sbin/runscript
-# Copyright 1999-2007 Gentoo Foundation
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2017-06-24  2:17 Michael Palimaka
  0 siblings, 0 replies; 10+ messages in thread
From: Michael Palimaka @ 2017-06-24  2:17 UTC (permalink / raw
  To: gentoo-commits

commit:     9e4f0cd8ae716aebec9ccb92994bb79eb65221e1
Author:     Michael Palimaka <kensington <AT> gentoo <DOT> org>
AuthorDate: Sat Jun 24 02:14:31 2017 +0000
Commit:     Michael Palimaka <kensington <AT> gentoo <DOT> org>
CommitDate: Sat Jun 24 02:16:50 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9e4f0cd8

net-p2p/amule: remove old

Package-Manager: Portage-2.3.5, Repoman-2.3.2

 net-p2p/amule/Manifest                      |   1 -
 net-p2p/amule/amule-2.3.1.ebuild            | 106 ----------------------------
 net-p2p/amule/files/amule-2.3.1-gcc47.patch |  21 ------
 3 files changed, 128 deletions(-)

diff --git a/net-p2p/amule/Manifest b/net-p2p/amule/Manifest
index 2503136cb44..bca0d5c4d74 100644
--- a/net-p2p/amule/Manifest
+++ b/net-p2p/amule/Manifest
@@ -1,2 +1 @@
-DIST aMule-2.3.1.tar.bz2 4565232 SHA256 d2eda19c34ec574fa123efb95726c7cc241b093c95d074a5161ee7330dece69d SHA512 3310aa6e92dde0e27df032da701bc28533c703277ddeec3766fb0e945725ed340b2d3fe54016172621a47559b6c13fb2893cba0d2469a1038ab35c3ee2d5a3c3 WHIRLPOOL 1e1a27ebaed1c8f49093dc6a75a0b9c5fd1ad5a3390585d08b1db2b8cd00397e2d519b01720d5d2131b779f9bc0137d9a6aba603117295b185c3db716cc7dba2
 DIST aMule-2.3.2.tar.xz 3895300 SHA256 f64720fdc8c6cfa06bdcd4ca3922d30a0ddddba9c897f5bec7605009c7683928 SHA512 3064b086f8459b4372ea0c11f239a08167c7beac3dde26889f056f617b480b487bea10c2cae8fdfa1ae99c10fc9e715adc8e01e4b968389861aa47c3ec8c0016 WHIRLPOOL 2907069f705dcb438fb78e049d9a417d42401bff659924c7ed66451b22c6dd35baf52e8100ca81e06c24cd1418ba586e16746bcb4e27314c15fd29407b4e3298

diff --git a/net-p2p/amule/amule-2.3.1.ebuild b/net-p2p/amule/amule-2.3.1.ebuild
deleted file mode 100644
index 528912006a8..00000000000
--- a/net-p2p/amule/amule-2.3.1.ebuild
+++ /dev/null
@@ -1,106 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="2"
-
-inherit eutils flag-o-matic wxwidgets user
-
-MY_P=${PN/m/M}-${PV}
-S="${WORKDIR}"/${MY_P}
-
-DESCRIPTION="aMule, the all-platform eMule p2p client"
-HOMEPAGE="http://www.amule.org/"
-SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 ppc ppc64 ~sparc x86"
-IUSE="daemon debug geoip nls remote stats unicode upnp +X"
-
-DEPEND=">=dev-libs/crypto++-5
-	>=sys-libs/zlib-1.2.1
-	stats? ( >=media-libs/gd-2.0.26[jpeg] )
-	geoip? ( dev-libs/geoip )
-	upnp? ( >=net-libs/libupnp-1.6.6 )
-	remote? ( >=media-libs/libpng-1.2.0
-	unicode? ( >=media-libs/gd-2.0.26 ) )
-	X? ( >=x11-libs/wxGTK-2.8.12:2.8[X] )
-	!X? ( >=x11-libs/wxGTK-2.8.12:2.8 )
-	!net-p2p/imule"
-RDEPEND="${DEPEND}"
-
-pkg_setup() {
-	if use stats && ! use X; then
-		einfo "Note: You would need both the X and stats USE flags"
-		einfo "to compile aMule Statistics GUI."
-		einfo "I will now compile console versions only."
-	fi
-}
-
-pkg_preinst() {
-	if use daemon || use remote; then
-		enewgroup p2p
-		enewuser p2p -1 -1 /home/p2p p2p
-	fi
-}
-
-src_prepare() {
-	epatch "${FILESDIR}"/${PN}-2.2.6-fallocate.diff
-	# Bug 412371
-	epatch "${FILESDIR}"/${PN}-2.3.1-gcc47.patch
-}
-
-src_configure() {
-	local myconf
-
-	WX_GTK_VER="2.8"
-
-	if use X; then
-		einfo "wxGTK with X support will be used"
-		need-wxwidgets unicode
-	else
-		einfo "wxGTK without X support will be used"
-		need-wxwidgets base-unicode
-	fi
-
-	if use X ; then
-		use stats && myconf="${myconf}
-			--enable-wxcas
-			--enable-alc"
-		use remote && myconf="${myconf}
-			--enable-amule-gui"
-	else
-		myconf="
-			--disable-monolithic
-			--disable-amule-gui
-			--disable-wxcas
-			--disable-alc"
-	fi
-
-	econf \
-		--with-wx-config=${WX_CONFIG} \
-		--enable-amulecmd \
-		$(use_enable debug) \
-		$(use_enable !debug optimize) \
-		$(use_enable daemon amule-daemon) \
-		$(use_enable geoip) \
-		$(use_enable nls) \
-		$(use_enable remote webserver) \
-		$(use_enable stats cas) \
-		$(use_enable stats alcc) \
-		$(use_enable upnp) \
-		${myconf} || die
-}
-
-src_install() {
-	emake DESTDIR="${D}" install || die
-
-	if use daemon; then
-		newconfd "${FILESDIR}"/amuled.confd amuled
-		newinitd "${FILESDIR}"/amuled.initd amuled
-	fi
-	if use remote; then
-		newconfd "${FILESDIR}"/amuleweb.confd amuleweb
-		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
-	fi
-}

diff --git a/net-p2p/amule/files/amule-2.3.1-gcc47.patch b/net-p2p/amule/files/amule-2.3.1-gcc47.patch
deleted file mode 100644
index e776dda3240..00000000000
--- a/net-p2p/amule/files/amule-2.3.1-gcc47.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-# http://code.google.com/p/amule/source/detail?r=10772
-diff -ur aMule-2.3.1.orig//src/ObservableQueue.h aMule-2.3.1/src/ObservableQueue.h
---- aMule-2.3.1.orig//src/ObservableQueue.h	2012-04-22 19:40:05.560084120 +0200
-+++ aMule-2.3.1/src/ObservableQueue.h	2012-04-22 19:40:32.479085322 +0200
-@@ -331,14 +331,14 @@
- template <typename ValueType>
- void CObservableQueue<ValueType>::ObserverAdded( ObserverType* o )
- {
--	NotifyObservers( EventType( EventType::STARTING ), o );
-+	this->NotifyObservers( EventType( EventType::STARTING ), o );
- }
- 
- 
- template <typename ValueType>
- void CObservableQueue<ValueType>::ObserverRemoved( ObserverType* o )
- {
--	NotifyObservers( EventType( EventType::STOPPING ), o );
-+	this->NotifyObservers( EventType( EventType::STOPPING ), o );
- }
- 
- 
\ No newline at end of file


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2019-04-22  7:26 Michał Górny
  0 siblings, 0 replies; 10+ messages in thread
From: Michał Górny @ 2019-04-22  7:26 UTC (permalink / raw
  To: gentoo-commits

commit:     e8dc99ed1e5f679d13ff5ecd1926bbb23d6a7dea
Author:     Alexander Tsoy <alexander <AT> tsoy <DOT> me>
AuthorDate: Mon Apr 15 20:58:34 2019 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Mon Apr 22 07:26:32 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e8dc99ed

net-p2p/amule: remove old and broken

Signed-off-by: Alexander Tsoy <alexander <AT> tsoy.me>
Package-Manager: Portage-2.3.62, Repoman-2.3.11
Closes: https://github.com/gentoo/gentoo/pull/11702
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 net-p2p/amule/amule-2.3.2-r1.ebuild            | 104 -------------------------
 net-p2p/amule/files/amule-2.2.6-fallocate.diff |  23 ------
 2 files changed, 127 deletions(-)

diff --git a/net-p2p/amule/amule-2.3.2-r1.ebuild b/net-p2p/amule/amule-2.3.2-r1.ebuild
deleted file mode 100644
index 51bb5d2472b..00000000000
--- a/net-p2p/amule/amule-2.3.2-r1.ebuild
+++ /dev/null
@@ -1,104 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-WX_GTK_VER="3.0"
-
-inherit wxwidgets user
-
-MY_P="${PN/m/M}-${PV}"
-S="${WORKDIR}/${MY_P}"
-
-DESCRIPTION="aMule, the all-platform eMule p2p client"
-HOMEPAGE="http://www.amule.org/"
-SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.xz"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 ~arm ppc ppc64 ~sparc x86"
-IUSE="daemon debug geoip nls remote stats unicode upnp +X"
-
-COMMON_DEPEND="
-	dev-libs/crypto++
-	sys-libs/binutils-libs:0=
-	sys-libs/zlib
-	x11-libs/wxGTK:${WX_GTK_VER}[X?]
-	stats? ( media-libs/gd:=[jpeg,png] )
-	geoip? ( dev-libs/geoip )
-	upnp? ( net-libs/libupnp:* )
-	remote? ( media-libs/libpng:0=
-	unicode? ( media-libs/gd:= ) )
-	!net-p2p/imule"
-DEPEND="${COMMON_DEPEND}"
-RDEPEND="${COMMON_DEPEND}"
-
-PATCHES=( "${FILESDIR}/${PN}-2.2.6-fallocate.diff" )
-
-pkg_setup() {
-	if use stats && ! use X; then
-		einfo "Note: You would need both the X and stats USE flags"
-		einfo "to compile aMule Statistics GUI."
-		einfo "I will now compile console versions only."
-	fi
-}
-
-pkg_preinst() {
-	if use daemon || use remote; then
-		enewgroup p2p
-		enewuser p2p -1 -1 /home/p2p p2p
-	fi
-}
-
-src_configure() {
-	local myconf
-
-	if use X; then
-		einfo "wxGTK with X support will be used"
-		need-wxwidgets unicode
-	else
-		einfo "wxGTK without X support will be used"
-		need-wxwidgets base-unicode
-	fi
-
-	if use X ; then
-		use stats && myconf="${myconf}
-			--enable-wxcas
-			--enable-alc"
-		use remote && myconf="${myconf}
-			--enable-amule-gui"
-	else
-		myconf="
-			--disable-monolithic
-			--disable-amule-gui
-			--disable-wxcas
-			--disable-alc"
-	fi
-
-	econf \
-		--with-denoise-level=0 \
-		--with-wx-config="${WX_CONFIG}" \
-		--enable-amulecmd \
-		--without-boost \
-		$(use_enable debug) \
-		$(use_enable daemon amule-daemon) \
-		$(use_enable geoip) \
-		$(use_enable nls) \
-		$(use_enable remote webserver) \
-		$(use_enable stats cas) \
-		$(use_enable stats alcc) \
-		$(use_enable upnp) \
-		${myconf}
-}
-
-src_install() {
-	default
-
-	if use daemon; then
-		newconfd "${FILESDIR}"/amuled.confd amuled
-		newinitd "${FILESDIR}"/amuled.initd amuled
-	fi
-	if use remote; then
-		newconfd "${FILESDIR}"/amuleweb.confd amuleweb
-		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
-	fi
-}

diff --git a/net-p2p/amule/files/amule-2.2.6-fallocate.diff b/net-p2p/amule/files/amule-2.2.6-fallocate.diff
deleted file mode 100644
index 8d1485a6778..00000000000
--- a/net-p2p/amule/files/amule-2.2.6-fallocate.diff
+++ /dev/null
@@ -1,23 +0,0 @@
-Disable fallocate #562992
-
-This is only a workaround to fix FTBFS, the configure check is wrong and needs to be fixed:
-http://www.amule.org/abugs/view.php?id=1572
-
---- a/src/ThreadTasks.cpp
-+++ b/src/ThreadTasks.cpp
-@@ -506,6 +506,15 @@ void CCompletionTask::OnExit()
- #include <stdlib.h>
- #include <errno.h>
- 
-+// #562992
-+#if defined(__alpha__) || defined(__hppa__)
-+#undef HAVE_FALLOCATE
-+#endif
-+
-+#if defined(__hppa__)
-+#undef HAVE_SYS_FALLOCATE
-+#endif
-+
- CAllocateFileTask::CAllocateFileTask(CPartFile *file, bool pause)
- 	// GetPrintable is used to improve the readability of the log.
- 	: CThreadTask(wxT("Allocating"), file->GetFullName().RemoveExt().GetPrintable(), ETP_High),


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2019-04-22  7:26 Michał Górny
  0 siblings, 0 replies; 10+ messages in thread
From: Michał Górny @ 2019-04-22  7:26 UTC (permalink / raw
  To: gentoo-commits

commit:     8875451f5ad348eccdf92ea47136b791be2bb599
Author:     Alexander Tsoy <alexander <AT> tsoy <DOT> me>
AuthorDate: Mon Apr 15 20:55:15 2019 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Mon Apr 22 07:26:32 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8875451f

net-p2p/amule: revbump for wxGTK:3.0-gtk3

Add upstream patch fixing crashes with wxGTK:3.0-gtk3.
Also fix configure logic.

Signed-off-by: Alexander Tsoy <alexander <AT> tsoy.me>
Package-Manager: Portage-2.3.62, Repoman-2.3.11
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 net-p2p/amule/amule-2.3.2-r3.ebuild                | 106 +++++++++++++++++++++
 ...2.3.2-fix-crash-when-shared-files-changed.patch |  50 ++++++++++
 2 files changed, 156 insertions(+)

diff --git a/net-p2p/amule/amule-2.3.2-r3.ebuild b/net-p2p/amule/amule-2.3.2-r3.ebuild
new file mode 100644
index 00000000000..7a7035ef43e
--- /dev/null
+++ b/net-p2p/amule/amule-2.3.2-r3.ebuild
@@ -0,0 +1,106 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+WX_GTK_VER="3.0-gtk3"
+
+inherit wxwidgets user
+
+MY_P="${PN/m/M}-${PV}"
+S="${WORKDIR}/${MY_P}"
+
+DESCRIPTION="aMule, the all-platform eMule p2p client"
+HOMEPAGE="http://www.amule.org/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ppc ~ppc64 ~sparc ~x86"
+IUSE="daemon debug geoip nls remote stats upnp +X"
+
+COMMON_DEPEND="
+	dev-libs/boost:=
+	dev-libs/crypto++:=
+	sys-libs/binutils-libs:0=
+	sys-libs/zlib
+	>=x11-libs/wxGTK-3.0.4:${WX_GTK_VER}[X?]
+	stats? ( media-libs/gd:=[jpeg,png] )
+	geoip? ( dev-libs/geoip )
+	upnp? ( net-libs/libupnp:* )
+	remote? ( media-libs/libpng:0= )
+	!net-p2p/imule"
+DEPEND="${COMMON_DEPEND}"
+RDEPEND="${COMMON_DEPEND}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-shared-dir-utf8.patch"
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-1.patch"
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-2.patch"
+	"${FILESDIR}/${PN}-2.3.2-cryptopp-6.patch"
+	"${FILESDIR}/${PN}-2.3.2-disable-version-check.patch"
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-when-shared-files-changed.patch"
+)
+
+pkg_setup() {
+	if use stats && ! use X; then
+		einfo "Note: You would need both the X and stats USE flags"
+		einfo "to compile aMule Statistics GUI."
+		einfo "I will now compile console versions only."
+	fi
+
+	setup-wxwidgets
+}
+
+pkg_preinst() {
+	if use daemon || use remote; then
+		enewgroup p2p
+		enewuser p2p -1 -1 /home/p2p p2p
+	fi
+}
+
+src_configure() {
+	local myconf
+
+	if use X; then
+		myconf="
+			$(use_enable remote amule-gui)
+			$(use_enable stats alc)
+			$(use_enable stats wxcas)
+		"
+	else
+		myconf="
+			--disable-monolithic
+			--disable-amule-gui
+			--disable-alc
+			--disable-wxcas
+		"
+	fi
+
+	econf \
+		--with-denoise-level=0 \
+		--with-wx-config="${WX_CONFIG}" \
+		--enable-amulecmd \
+		--with-boost \
+		$(use_enable debug) \
+		$(use_enable daemon amule-daemon) \
+		$(use_enable geoip) \
+		$(use_enable nls) \
+		$(use_enable remote webserver) \
+		$(use_enable stats cas) \
+		$(use_enable stats alcc) \
+		$(use_enable upnp) \
+		${myconf}
+}
+
+src_install() {
+	default
+
+	if use daemon; then
+		newconfd "${FILESDIR}"/amuled.confd amuled
+		newinitd "${FILESDIR}"/amuled.initd amuled
+	fi
+	if use remote; then
+		newconfd "${FILESDIR}"/amuleweb.confd amuleweb
+		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
+	fi
+}

diff --git a/net-p2p/amule/files/amule-2.3.2-fix-crash-when-shared-files-changed.patch b/net-p2p/amule/files/amule-2.3.2-fix-crash-when-shared-files-changed.patch
new file mode 100644
index 00000000000..81e0ef7b629
--- /dev/null
+++ b/net-p2p/amule/files/amule-2.3.2-fix-crash-when-shared-files-changed.patch
@@ -0,0 +1,50 @@
+From 110a056fa4bcfc0fe8c1f8eadcc2bd5df0bbf5e1 Mon Sep 17 00:00:00 2001
+From: xinhuang <xinhuang.abc@gmail.com>
+Date: Thu, 4 Jan 2018 00:44:35 -0800
+Subject: [PATCH] fix crash when shared files changed on Shared files tab
+
+---
+ src/extern/wxWidgets/listctrl.cpp | 10 ----------
+ src/extern/wxWidgets/listctrl.h   |  5 -----
+ 2 files changed, 15 deletions(-)
+
+diff --git a/src/extern/wxWidgets/listctrl.cpp b/src/extern/wxWidgets/listctrl.cpp
+index 18a30f205..460700691 100644
+--- a/src/extern/wxWidgets/listctrl.cpp
++++ b/src/extern/wxWidgets/listctrl.cpp
+@@ -5803,16 +5803,6 @@ bool wxGenericListCtrl::DoPopupMenu( wxMenu *menu, int x, int y )
+ #endif
+ }
+ 
+-void wxGenericListCtrl::DoClientToScreen( int *x, int *y ) const
+-{
+-    m_mainWin->DoClientToScreen(x, y);
+-}
+-
+-void wxGenericListCtrl::DoScreenToClient( int *x, int *y ) const
+-{
+-    m_mainWin->DoScreenToClient(x, y);
+-}
+-
+ void wxGenericListCtrl::SetFocus()
+ {
+     // The test in window.cpp fails as we are a composite
+diff --git a/src/extern/wxWidgets/listctrl.h b/src/extern/wxWidgets/listctrl.h
+index b18a61866..e72f7eaf0 100644
+--- a/src/extern/wxWidgets/listctrl.h
++++ b/src/extern/wxWidgets/listctrl.h
+@@ -232,11 +232,6 @@ public:
+ protected:
+     virtual bool DoPopupMenu( wxMenu *menu, int x, int y );
+ 
+-    // take into account the coordinates difference between the container
+-    // window and the list control window itself here
+-    virtual void DoClientToScreen( int *x, int *y ) const;
+-    virtual void DoScreenToClient( int *x, int *y ) const;
+-
+     virtual wxSize DoGetBestSize() const;
+ 
+     // return the text for the given column of the given item
+-- 
+2.21.0
+


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2020-01-17  6:23 Joonas Niilola
  0 siblings, 0 replies; 10+ messages in thread
From: Joonas Niilola @ 2020-01-17  6:23 UTC (permalink / raw
  To: gentoo-commits

commit:     34130dbd1646b428aa766cb957629ed6e7c270cb
Author:     Alexander Tsoy <alexander <AT> tsoy <DOT> me>
AuthorDate: Sat Aug 10 01:01:18 2019 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Fri Jan 17 06:23:37 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=34130dbd

net-p2p/amule: EAPI=7 bump

* add missing pkgconfig dependency
* convert myconf variable to array
* remove obsolete imule blocker
* fix license
* fix build with >=net-libs/libupnp-1.8
* switch to acct-{user,group}

Signed-off-by: Alexander Tsoy <alexander <AT> tsoy.me>
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 net-p2p/amule/amule-2.3.2-r4.ebuild               | 126 ++++++++
 net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch | 350 ++++++++++++++++++++++
 net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch | 263 ++++++++++++++++
 net-p2p/amule/files/amuled.confd-r1               |   9 +
 net-p2p/amule/files/amuleweb.confd-r1             |  24 ++
 5 files changed, 772 insertions(+)

diff --git a/net-p2p/amule/amule-2.3.2-r4.ebuild b/net-p2p/amule/amule-2.3.2-r4.ebuild
new file mode 100644
index 00000000000..8199a8471f0
--- /dev/null
+++ b/net-p2p/amule/amule-2.3.2-r4.ebuild
@@ -0,0 +1,126 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+WX_GTK_VER="3.0-gtk3"
+
+inherit wxwidgets
+
+MY_P="${PN/m/M}-${PV}"
+
+DESCRIPTION="aMule, the all-platform eMule p2p client"
+HOMEPAGE="http://www.amule.org/"
+SRC_URI="https://download.sourceforge.net/${PN}/${MY_P}.tar.xz"
+S="${WORKDIR}/${MY_P}"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ppc ~ppc64 ~sparc ~x86"
+IUSE="daemon debug geoip nls remote stats upnp +X"
+
+RDEPEND="
+	dev-libs/boost:=
+	dev-libs/crypto++:=
+	sys-libs/binutils-libs:0=
+	sys-libs/zlib
+	>=x11-libs/wxGTK-3.0.4:${WX_GTK_VER}[X?]
+	daemon? ( acct-user/amule )
+	geoip? ( dev-libs/geoip )
+	remote? (
+		acct-user/amule
+		media-libs/libpng:0=
+	)
+	stats? ( media-libs/gd:=[jpeg,png] )
+	upnp? ( net-libs/libupnp:0 )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-shared-dir-utf8.patch"
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-1.patch"
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-2.patch"
+	"${FILESDIR}/${PN}-2.3.2-cryptopp-6.patch"
+	"${FILESDIR}/${PN}-2.3.2-disable-version-check.patch"
+	"${FILESDIR}/${PN}-2.3.2-fix-crash-when-shared-files-changed.patch"
+	"${FILESDIR}/${PN}-2.3.2-libupnp-1.8.patch"
+	"${FILESDIR}/${PN}-2.3.2-libupnp-1.6.patch"
+)
+
+pkg_setup() {
+	setup-wxwidgets
+}
+
+src_configure() {
+	local myconf=(
+		--with-denoise-level=0
+		--with-wx-config="${WX_CONFIG}"
+		--enable-amulecmd
+		--with-boost
+		$(use_enable debug)
+		$(use_enable daemon amule-daemon)
+		$(use_enable geoip)
+		$(use_enable nls)
+		$(use_enable remote webserver)
+		$(use_enable stats cas)
+		$(use_enable stats alcc)
+		$(use_enable upnp)
+	)
+
+	if use X; then
+		myconf+=(
+			$(use_enable remote amule-gui)
+			$(use_enable stats alc)
+			$(use_enable stats wxcas)
+		)
+	else
+		myconf+=(
+			--disable-monolithic
+			--disable-amule-gui
+			--disable-alc
+			--disable-wxcas
+		)
+	fi
+
+	econf "${myconf[@]}"
+}
+
+src_install() {
+	default
+
+	if use daemon; then
+		newconfd "${FILESDIR}"/amuled.confd-r1 amuled
+		newinitd "${FILESDIR}"/amuled.initd amuled
+	fi
+	if use remote; then
+		newconfd "${FILESDIR}"/amuleweb.confd-r1 amuleweb
+		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
+	fi
+
+	if use daemon || use remote; then
+		keepdir /var/lib/${PN}
+		fowners amule:amule /var/lib/${PN}
+		fperms 0750 /var/lib/${PN}
+	fi
+}
+
+pkg_postinst() {
+	local ver
+
+	if use daemon || use remote; then
+		for ver in ${REPLACING_VERSIONS}; do
+			if ver_test ${ver} -lt "2.3.2-r4"; then
+				elog "Default user under which amuled and amuleweb daemons are started"
+				elog "have been changed from p2p to amule. Default home directory have been"
+				elog "changed as well."
+				echo
+				elog "If you want to preserve old download/share location, you can create"
+				elog "symlink /var/lib/amule/.aMule pointing to the old location and adjust"
+				elog "files ownership *or* restore AMULEUSER and AMULEHOME variables in"
+				elog "/etc/conf.d/{amuled,amuleweb} to the old values."
+
+				break
+			fi
+		done
+	fi
+}

diff --git a/net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch b/net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch
new file mode 100644
index 00000000000..0fd0edfbd8f
--- /dev/null
+++ b/net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch
@@ -0,0 +1,350 @@
+From cb30875bd4e45736ff4ee1137ff97316295ff7be Mon Sep 17 00:00:00 2001
+From: Pablo Barciela <scow@riseup.net>
+Date: Sat, 24 Nov 2018 01:23:58 +0100
+Subject: [PATCH] Fix build with libupnp 1.6
+
+---
+ src/UPnPBase.cpp | 138 ++++++++++++++++++++++++++++++++++++++++++++++-
+ src/UPnPBase.h   |   6 +++
+ 2 files changed, 142 insertions(+), 2 deletions(-)
+
+diff --git a/src/UPnPBase.cpp b/src/UPnPBase.cpp
+index d4063a136..774ebfc32 100644
+--- a/src/UPnPBase.cpp
++++ b/src/UPnPBase.cpp
+@@ -1127,7 +1127,11 @@ bool CUPnPControlPoint::PrivateDeletePortMapping(
+ 
+ 
+ // This function is static
++#if UPNP_VERSION >= 10800
+ int CUPnPControlPoint::Callback(Upnp_EventType_e EventType, const void *Event, void * /*Cookie*/)
++#else
++int CUPnPControlPoint::Callback(Upnp_EventType EventType, void *Event, void * /*Cookie*/)
++#endif
+ {
+ 	std::ostringstream msg;
+ 	std::ostringstream msg2;
+@@ -1149,25 +1153,47 @@ int CUPnPControlPoint::Callback(Upnp_EventType_e EventType, const void *Event, v
+ 		msg2<< "UPNP_DISCOVERY_SEARCH_RESULT: ";
+ 		// UPnP Discovery
+ upnpDiscovery:
++#if UPNP_VERSION >= 10800
+ 		UpnpDiscovery *d_event = (UpnpDiscovery *)Event;
++#else
++		struct Upnp_Discovery *d_event = (struct Upnp_Discovery *)Event;
++#endif
+ 		IXML_Document *doc = NULL;
++#if UPNP_VERSION >= 10800
+ 		int errCode = UpnpDiscovery_get_ErrCode(d_event);
+ 		if (errCode != UPNP_E_SUCCESS) {
+ 			msg << UpnpGetErrorMessage(errCode) << ".";
++#else
++		int ret;
++		if (d_event->ErrCode != UPNP_E_SUCCESS) {
++			msg << UpnpGetErrorMessage(d_event->ErrCode) << ".";
++#endif
+ 			AddDebugLogLineC(logUPnP, msg);
+ 		}
+ 		// Get the XML tree device description in doc
++#if UPNP_VERSION >= 10800
+ 		const char *location = UpnpDiscovery_get_Location_cstr(d_event);
+ 		int ret = UpnpDownloadXmlDoc(location, &doc);
++#else
++		ret = UpnpDownloadXmlDoc(d_event->Location, &doc);
++#endif
+ 		if (ret != UPNP_E_SUCCESS) {
+ 			msg << "Error retrieving device description from " <<
++#if UPNP_VERSION >= 10800
+ 				location << ": " <<
++#else
++				d_event->Location << ": " <<
++#endif
+ 				UpnpGetErrorMessage(ret) <<
+ 				"(" << ret << ").";
+ 			AddDebugLogLineC(logUPnP, msg);
+ 		} else {
+ 			msg2 << "Retrieving device description from " <<
++#if UPNP_VERSION >= 10800
+ 				location << ".";
++#else
++				d_event->Location << ".";
++#endif
+ 			AddDebugLogLineN(logUPnP, msg2);
+ 		}
+ 		if (doc) {
+@@ -1195,9 +1221,14 @@ upnpDiscovery:
+ 					AddDebugLogLineC(logUPnP, msg);
+ 				}
+ 				// Add the root device to our list
++#if UPNP_VERSION >= 10800
+ 				int expires = UpnpDiscovery_get_Expires(d_event);
+ 				upnpCP->AddRootDevice(rootDevice, urlBase,
+ 					location, expires);
++#else
++				upnpCP->AddRootDevice(rootDevice, urlBase,
++					d_event->Location, d_event->Expires);
++#endif
+ 			}
+ 			// Free the XML doc tree
+ 			IXML::Document::Free(doc);
+@@ -1218,35 +1249,62 @@ upnpDiscovery:
+ 	case UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE: {
+ 		//fprintf(stderr, "Callback: UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE\n");
+ 		// UPnP Device Removed
++#if UPNP_VERSION >= 10800
+ 		UpnpDiscovery *dab_event = (UpnpDiscovery *)Event;
+ 		int errCode = UpnpDiscovery_get_ErrCode(dab_event);
+ 		if (errCode != UPNP_E_SUCCESS) {
++#else
++		struct Upnp_Discovery *dab_event = (struct Upnp_Discovery *)Event;
++		if (dab_event->ErrCode != UPNP_E_SUCCESS) {
++#endif
+ 			msg << "error(UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE): " <<
++#if UPNP_VERSION >= 10800
+ 				UpnpGetErrorMessage(errCode) <<
++#else
++				UpnpGetErrorMessage(dab_event->ErrCode) <<
++#endif
+ 				".";
+ 			AddDebugLogLineC(logUPnP, msg);
+ 		}
++#if UPNP_VERSION >= 10800
+ 		std::string devType = UpnpDiscovery_get_DeviceType_cstr(dab_event);
++#else
++		std::string devType = dab_event->DeviceType;
++#endif
+ 		// Check for an InternetGatewayDevice and removes it from the list
+-		std::transform(devType.begin(), devType.end(),
+-			devType.begin(), tolower);
++
++		std::transform(devType.begin(), devType.end(), devType.begin(), tolower);
++
+ 		if (stdStringIsEqualCI(devType, UPnP::Device::IGW)) {
++#if UPNP_VERSION >= 10800
+ 			const char *deviceID =
+ 				UpnpDiscovery_get_DeviceID_cstr(dab_event);
+ 			upnpCP->RemoveRootDevice(deviceID);
++#else
++			upnpCP->RemoveRootDevice(dab_event->DeviceId);
++#endif
+ 		}
+ 		break;
+ 	}
+ 	case UPNP_EVENT_RECEIVED: {
+ 		//fprintf(stderr, "Callback: UPNP_EVENT_RECEIVED\n");
+ 		// Event reveived
++#if UPNP_VERSION >= 10800
+ 		UpnpEvent *e_event = (UpnpEvent *)Event;
+ 		int eventKey = UpnpEvent_get_EventKey(e_event);
+ 		IXML_Document *changedVariables =
+ 			UpnpEvent_get_ChangedVariables(e_event);
+ 		const std::string sid = UpnpEvent_get_SID_cstr(e_event);
++#else
++		struct Upnp_Event *e_event = (struct Upnp_Event *)Event;
++		const std::string Sid = e_event->Sid;
++#endif
+ 		// Parses the event
++#if UPNP_VERSION >= 10800
+ 		upnpCP->OnEventReceived(sid, eventKey, changedVariables);
++#else
++		upnpCP->OnEventReceived(Sid, e_event->EventKey, e_event->ChangedVariables);
++#endif
+ 		break;
+ 	}
+ 	case UPNP_EVENT_SUBSCRIBE_COMPLETE:
+@@ -1261,19 +1319,38 @@ upnpDiscovery:
+ 		//fprintf(stderr, "Callback: UPNP_EVENT_RENEWAL_COMPLETE\n");
+ 		msg << "error(UPNP_EVENT_RENEWAL_COMPLETE): ";
+ upnpEventRenewalComplete:
++#if UPNP_VERSION >= 10800
+ 		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
+ 		int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
+ 		if (errCode != UPNP_E_SUCCESS) {
++#else
++		struct Upnp_Event_Subscribe *es_event =
++			(struct Upnp_Event_Subscribe *)Event;
++		if (es_event->ErrCode != UPNP_E_SUCCESS) {
++#endif
+ 			msg << "Error in Event Subscribe Callback";
++#if UPNP_VERSION >= 10800
+ 			UPnP::ProcessErrorMessage(msg.str(), errCode, NULL, NULL);
++#else
++			UPnP::ProcessErrorMessage(
++				msg.str(), es_event->ErrCode, NULL, NULL);
++#endif
+ 		} else {
+ #if 0
++#if UPNP_VERSION >= 10800
++
+ 			const UpnpString *publisherUrl =
+ 				UpnpEventSubscribe_get_PublisherUrl(es_event);
+ 			const char *sid = UpnpEvent_get_SID_cstr(es_event);
+ 			int timeOut = UpnpEvent_get_TimeOut(es_event);
+ 			TvCtrlPointHandleSubscribeUpdate(
+ 				publisherUrl, sid, timeOut);
++#else
++			TvCtrlPointHandleSubscribeUpdate(
++				GET_UPNP_STRING(es_event->PublisherUrl),
++				es_event->Sid,
++				es_event->TimeOut );
++#endif
+ #endif
+ 		}
+ 		break;
+@@ -1288,31 +1365,56 @@ upnpEventRenewalComplete:
+ 		msg << "error(UPNP_EVENT_SUBSCRIPTION_EXPIRED): ";
+ 		msg2 << "UPNP_EVENT_SUBSCRIPTION_EXPIRED: ";
+ upnpEventSubscriptionExpired:
++#if UPNP_VERSION >= 10800
+ 		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
++#else
++		struct Upnp_Event_Subscribe *es_event =
++			(struct Upnp_Event_Subscribe *)Event;
++#endif
+ 		Upnp_SID newSID;
+ 		memset(newSID, 0, sizeof(Upnp_SID));
+ 		int TimeOut = 1801;
++#if UPNP_VERSION >= 10800
+ 		const char *publisherUrl =
+ 			UpnpEventSubscribe_get_PublisherUrl_cstr(es_event);
++#endif
+ 		int ret = UpnpSubscribe(
+ 			upnpCP->m_UPnPClientHandle,
++#if UPNP_VERSION >= 10800
+ 			publisherUrl,
++#else
++			GET_UPNP_STRING(es_event->PublisherUrl),
++#endif
+ 			&TimeOut,
+ 			newSID);
+ 		if (ret != UPNP_E_SUCCESS) {
+ 			msg << "Error Subscribing to EventURL";
++#if UPNP_VERSION >= 10800
+ 			int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
++#endif
+ 			UPnP::ProcessErrorMessage(
++#if UPNP_VERSION >= 10800
+ 				msg.str(), errCode, NULL, NULL);
++#else
++				msg.str(), es_event->ErrCode, NULL, NULL);
++#endif
+ 		} else {
+ 			ServiceMap::iterator it =
++#if UPNP_VERSION >= 10800
+ 				upnpCP->m_ServiceMap.find(publisherUrl);
++#else
++				upnpCP->m_ServiceMap.find(GET_UPNP_STRING(es_event->PublisherUrl));
++#endif
+ 			if (it != upnpCP->m_ServiceMap.end()) {
+ 				CUPnPService &service = *(it->second);
+ 				service.SetTimeout(TimeOut);
+ 				service.SetSID(newSID);
+ 				msg2 << "Re-subscribed to EventURL '" <<
++#if UPNP_VERSION >= 10800
+ 					publisherUrl <<
++#else
++					GET_UPNP_STRING(es_event->PublisherUrl) <<
++#endif
+ 					"' with SID == '" <<
+ 					newSID << "'.";
+ 				AddDebugLogLineC(logUPnP, msg2);
+@@ -1331,19 +1433,34 @@ upnpEventSubscriptionExpired:
+ 	case UPNP_CONTROL_ACTION_COMPLETE: {
+ 		//fprintf(stderr, "Callback: UPNP_CONTROL_ACTION_COMPLETE\n");
+ 		// This is here if we choose to do this asynchronously
++#if UPNP_VERSION >= 10800
+ 		UpnpActionComplete *a_event = (UpnpActionComplete *)Event;
+ 		int errCode = UpnpActionComplete_get_ErrCode(a_event);
+ 		IXML_Document *actionResult =
+ 			UpnpActionComplete_get_ActionResult(a_event);
+ 		if (errCode != UPNP_E_SUCCESS) {
++#else
++		struct Upnp_Action_Complete *a_event =
++			(struct Upnp_Action_Complete *)Event;
++		if (a_event->ErrCode != UPNP_E_SUCCESS) {
++#endif
+ 			UPnP::ProcessErrorMessage(
+ 				"UpnpSendActionAsync",
++#if UPNP_VERSION >= 10800
+ 				errCode, NULL,
+ 				actionResult);
++#else
++				a_event->ErrCode, NULL,
++				a_event->ActionResult);
++#endif
+ 		} else {
+ 			// Check the response document
+ 			UPnP::ProcessActionResponse(
++#if UPNP_VERSION >= 10800
+ 				actionResult,
++#else
++				a_event->ActionResult,
++#endif
+ 				"<UpnpSendActionAsync>");
+ 		}
+ 		/* No need for any processing here, just print out results.
+@@ -1354,17 +1471,28 @@ upnpEventSubscriptionExpired:
+ 	case UPNP_CONTROL_GET_VAR_COMPLETE: {
+ 		//fprintf(stderr, "Callback: UPNP_CONTROL_GET_VAR_COMPLETE\n");
+ 		msg << "error(UPNP_CONTROL_GET_VAR_COMPLETE): ";
++#if UPNP_VERSION >= 10800
+ 		UpnpStateVarComplete *sv_event = (UpnpStateVarComplete *)Event;
+ 		int errCode = UpnpStateVarComplete_get_ErrCode(sv_event);
+ 		if (errCode != UPNP_E_SUCCESS) {
++#else
++		struct Upnp_State_Var_Complete *sv_event =
++			(struct Upnp_State_Var_Complete *)Event;
++		if (sv_event->ErrCode != UPNP_E_SUCCESS) {
++#endif
+ 			msg << "m_UpnpGetServiceVarStatusAsync";
+ 			UPnP::ProcessErrorMessage(
++#if UPNP_VERSION >= 10800
+ 				msg.str(), errCode, NULL, NULL);
++#else
++				msg.str(), sv_event->ErrCode, NULL, NULL);
++#endif
+ 		} else {
+ #if 0
+ 			// Warning: The use of UpnpGetServiceVarStatus and
+ 			// UpnpGetServiceVarStatusAsync is deprecated by the
+ 			// UPnP forum.
++#if UPNP_VERSION >= 10800
+ 			const char *ctrlUrl =
+ 				UpnpStateVarComplete_get_CtrlUrl(sv_event);
+ 			const char *stateVarName =
+@@ -1373,6 +1501,12 @@ upnpEventSubscriptionExpired:
+ 				UpnpStateVarComplete_get_CurrentVal(sv_event);
+ 			TvCtrlPointHandleGetVar(
+ 				ctrlUrl, stateVarName, currentVal);
++#else
++			TvCtrlPointHandleGetVar(
++				sv_event->CtrlUrl,
++				sv_event->StateVarName,
++				sv_event->CurrentVal );
++#endif
+ #endif
+ 		}
+ 		break;
+diff --git a/src/UPnPBase.h b/src/UPnPBase.h
+index 92753b86a..efe63bf0f 100644
+--- a/src/UPnPBase.h
++++ b/src/UPnPBase.h
+@@ -489,9 +489,15 @@ public:
+ 
+ 	// Callback function
+ 	static int Callback(
++#if UPNP_VERSION >= 10800
+ 		Upnp_EventType_e EventType,
+ 		const void *Event,
+ 		void *Cookie);
++#else
++		Upnp_EventType EventType,
++		void* Event,
++		void* Cookie);
++#endif
+ 
+ private:
+ 	void OnEventReceived(
+-- 
+2.24.1
+

diff --git a/net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch b/net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch
new file mode 100644
index 00000000000..42672a85a6a
--- /dev/null
+++ b/net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch
@@ -0,0 +1,263 @@
+From f6dccde218fed8dabd3c61efce02d29b320858fe Mon Sep 17 00:00:00 2001
+From: Marcelo Roberto Jimenez <marcelo.jimenez@gmail.com>
+Date: Tue, 2 Oct 2018 18:17:43 -0300
+Subject: [PATCH] Make aMule compatible with libupnp 1.8
+
+---
+ src/UPnPBase.cpp | 110 +++++++++++++++++++++++++++--------------------
+ src/UPnPBase.h   |   6 +--
+ 2 files changed, 66 insertions(+), 50 deletions(-)
+
+diff --git a/src/UPnPBase.cpp b/src/UPnPBase.cpp
+index 01a7c3a05..d4063a136 100644
+--- a/src/UPnPBase.cpp
++++ b/src/UPnPBase.cpp
+@@ -1127,7 +1127,7 @@ bool CUPnPControlPoint::PrivateDeletePortMapping(
+ 
+ 
+ // This function is static
+-int CUPnPControlPoint::Callback(Upnp_EventType EventType, void *Event, void * /*Cookie*/)
++int CUPnPControlPoint::Callback(Upnp_EventType_e EventType, const void *Event, void * /*Cookie*/)
+ {
+ 	std::ostringstream msg;
+ 	std::ostringstream msg2;
+@@ -1149,24 +1149,25 @@ int CUPnPControlPoint::Callback(Upnp_EventType EventType, void *Event, void * /*
+ 		msg2<< "UPNP_DISCOVERY_SEARCH_RESULT: ";
+ 		// UPnP Discovery
+ upnpDiscovery:
+-		struct Upnp_Discovery *d_event = (struct Upnp_Discovery *)Event;
++		UpnpDiscovery *d_event = (UpnpDiscovery *)Event;
+ 		IXML_Document *doc = NULL;
+-		int ret;
+-		if (d_event->ErrCode != UPNP_E_SUCCESS) {
+-			msg << UpnpGetErrorMessage(d_event->ErrCode) << ".";
++		int errCode = UpnpDiscovery_get_ErrCode(d_event);
++		if (errCode != UPNP_E_SUCCESS) {
++			msg << UpnpGetErrorMessage(errCode) << ".";
+ 			AddDebugLogLineC(logUPnP, msg);
+ 		}
+ 		// Get the XML tree device description in doc
+-		ret = UpnpDownloadXmlDoc(d_event->Location, &doc);
++		const char *location = UpnpDiscovery_get_Location_cstr(d_event);
++		int ret = UpnpDownloadXmlDoc(location, &doc);
+ 		if (ret != UPNP_E_SUCCESS) {
+ 			msg << "Error retrieving device description from " <<
+-				d_event->Location << ": " <<
++				location << ": " <<
+ 				UpnpGetErrorMessage(ret) <<
+ 				"(" << ret << ").";
+ 			AddDebugLogLineC(logUPnP, msg);
+ 		} else {
+ 			msg2 << "Retrieving device description from " <<
+-				d_event->Location << ".";
++				location << ".";
+ 			AddDebugLogLineN(logUPnP, msg2);
+ 		}
+ 		if (doc) {
+@@ -1194,8 +1195,9 @@ upnpDiscovery:
+ 					AddDebugLogLineC(logUPnP, msg);
+ 				}
+ 				// Add the root device to our list
++				int expires = UpnpDiscovery_get_Expires(d_event);
+ 				upnpCP->AddRootDevice(rootDevice, urlBase,
+-					d_event->Location, d_event->Expires);
++					location, expires);
+ 			}
+ 			// Free the XML doc tree
+ 			IXML::Document::Free(doc);
+@@ -1216,28 +1218,35 @@ upnpDiscovery:
+ 	case UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE: {
+ 		//fprintf(stderr, "Callback: UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE\n");
+ 		// UPnP Device Removed
+-		struct Upnp_Discovery *dab_event = (struct Upnp_Discovery *)Event;
+-		if (dab_event->ErrCode != UPNP_E_SUCCESS) {
++		UpnpDiscovery *dab_event = (UpnpDiscovery *)Event;
++		int errCode = UpnpDiscovery_get_ErrCode(dab_event);
++		if (errCode != UPNP_E_SUCCESS) {
+ 			msg << "error(UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE): " <<
+-				UpnpGetErrorMessage(dab_event->ErrCode) <<
++				UpnpGetErrorMessage(errCode) <<
+ 				".";
+ 			AddDebugLogLineC(logUPnP, msg);
+ 		}
+-		std::string devType = dab_event->DeviceType;
++		std::string devType = UpnpDiscovery_get_DeviceType_cstr(dab_event);
+ 		// Check for an InternetGatewayDevice and removes it from the list
+-		std::transform(devType.begin(), devType.end(), devType.begin(), tolower);
++		std::transform(devType.begin(), devType.end(),
++			devType.begin(), tolower);
+ 		if (stdStringIsEqualCI(devType, UPnP::Device::IGW)) {
+-			upnpCP->RemoveRootDevice(dab_event->DeviceId);
++			const char *deviceID =
++				UpnpDiscovery_get_DeviceID_cstr(dab_event);
++			upnpCP->RemoveRootDevice(deviceID);
+ 		}
+ 		break;
+ 	}
+ 	case UPNP_EVENT_RECEIVED: {
+ 		//fprintf(stderr, "Callback: UPNP_EVENT_RECEIVED\n");
+ 		// Event reveived
+-		struct Upnp_Event *e_event = (struct Upnp_Event *)Event;
+-		const std::string Sid = e_event->Sid;
++		UpnpEvent *e_event = (UpnpEvent *)Event;
++		int eventKey = UpnpEvent_get_EventKey(e_event);
++		IXML_Document *changedVariables =
++			UpnpEvent_get_ChangedVariables(e_event);
++		const std::string sid = UpnpEvent_get_SID_cstr(e_event);
+ 		// Parses the event
+-		upnpCP->OnEventReceived(Sid, e_event->EventKey, e_event->ChangedVariables);
++		upnpCP->OnEventReceived(sid, eventKey, changedVariables);
+ 		break;
+ 	}
+ 	case UPNP_EVENT_SUBSCRIBE_COMPLETE:
+@@ -1252,24 +1261,23 @@ upnpDiscovery:
+ 		//fprintf(stderr, "Callback: UPNP_EVENT_RENEWAL_COMPLETE\n");
+ 		msg << "error(UPNP_EVENT_RENEWAL_COMPLETE): ";
+ upnpEventRenewalComplete:
+-		struct Upnp_Event_Subscribe *es_event =
+-			(struct Upnp_Event_Subscribe *)Event;
+-		if (es_event->ErrCode != UPNP_E_SUCCESS) {
++		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
++		int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
++		if (errCode != UPNP_E_SUCCESS) {
+ 			msg << "Error in Event Subscribe Callback";
+-			UPnP::ProcessErrorMessage(
+-				msg.str(), es_event->ErrCode, NULL, NULL);
++			UPnP::ProcessErrorMessage(msg.str(), errCode, NULL, NULL);
+ 		} else {
+ #if 0
++			const UpnpString *publisherUrl =
++				UpnpEventSubscribe_get_PublisherUrl(es_event);
++			const char *sid = UpnpEvent_get_SID_cstr(es_event);
++			int timeOut = UpnpEvent_get_TimeOut(es_event);
+ 			TvCtrlPointHandleSubscribeUpdate(
+-				GET_UPNP_STRING(es_event->PublisherUrl),
+-				es_event->Sid,
+-				es_event->TimeOut );
++				publisherUrl, sid, timeOut);
+ #endif
+ 		}
+-
+ 		break;
+ 	}
+-
+ 	case UPNP_EVENT_AUTORENEWAL_FAILED:
+ 		//fprintf(stderr, "Callback: UPNP_EVENT_AUTORENEWAL_FAILED\n");
+ 		msg << "error(UPNP_EVENT_AUTORENEWAL_FAILED): ";
+@@ -1280,29 +1288,31 @@ upnpEventRenewalComplete:
+ 		msg << "error(UPNP_EVENT_SUBSCRIPTION_EXPIRED): ";
+ 		msg2 << "UPNP_EVENT_SUBSCRIPTION_EXPIRED: ";
+ upnpEventSubscriptionExpired:
+-		struct Upnp_Event_Subscribe *es_event =
+-			(struct Upnp_Event_Subscribe *)Event;
++		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
+ 		Upnp_SID newSID;
+ 		memset(newSID, 0, sizeof(Upnp_SID));
+ 		int TimeOut = 1801;
++		const char *publisherUrl =
++			UpnpEventSubscribe_get_PublisherUrl_cstr(es_event);
+ 		int ret = UpnpSubscribe(
+ 			upnpCP->m_UPnPClientHandle,
+-			GET_UPNP_STRING(es_event->PublisherUrl),
++			publisherUrl,
+ 			&TimeOut,
+ 			newSID);
+ 		if (ret != UPNP_E_SUCCESS) {
+ 			msg << "Error Subscribing to EventURL";
++			int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
+ 			UPnP::ProcessErrorMessage(
+-				msg.str(), es_event->ErrCode, NULL, NULL);
++				msg.str(), errCode, NULL, NULL);
+ 		} else {
+ 			ServiceMap::iterator it =
+-				upnpCP->m_ServiceMap.find(GET_UPNP_STRING(es_event->PublisherUrl));
++				upnpCP->m_ServiceMap.find(publisherUrl);
+ 			if (it != upnpCP->m_ServiceMap.end()) {
+ 				CUPnPService &service = *(it->second);
+ 				service.SetTimeout(TimeOut);
+ 				service.SetSID(newSID);
+ 				msg2 << "Re-subscribed to EventURL '" <<
+-					GET_UPNP_STRING(es_event->PublisherUrl) <<
++					publisherUrl <<
+ 					"' with SID == '" <<
+ 					newSID << "'.";
+ 				AddDebugLogLineC(logUPnP, msg2);
+@@ -1321,17 +1331,19 @@ upnpEventSubscriptionExpired:
+ 	case UPNP_CONTROL_ACTION_COMPLETE: {
+ 		//fprintf(stderr, "Callback: UPNP_CONTROL_ACTION_COMPLETE\n");
+ 		// This is here if we choose to do this asynchronously
+-		struct Upnp_Action_Complete *a_event =
+-			(struct Upnp_Action_Complete *)Event;
+-		if (a_event->ErrCode != UPNP_E_SUCCESS) {
++		UpnpActionComplete *a_event = (UpnpActionComplete *)Event;
++		int errCode = UpnpActionComplete_get_ErrCode(a_event);
++		IXML_Document *actionResult =
++			UpnpActionComplete_get_ActionResult(a_event);
++		if (errCode != UPNP_E_SUCCESS) {
+ 			UPnP::ProcessErrorMessage(
+ 				"UpnpSendActionAsync",
+-				a_event->ErrCode, NULL,
+-				a_event->ActionResult);
++				errCode, NULL,
++				actionResult);
+ 		} else {
+ 			// Check the response document
+ 			UPnP::ProcessActionResponse(
+-				a_event->ActionResult,
++				actionResult,
+ 				"<UpnpSendActionAsync>");
+ 		}
+ 		/* No need for any processing here, just print out results.
+@@ -1342,21 +1354,25 @@ upnpEventSubscriptionExpired:
+ 	case UPNP_CONTROL_GET_VAR_COMPLETE: {
+ 		//fprintf(stderr, "Callback: UPNP_CONTROL_GET_VAR_COMPLETE\n");
+ 		msg << "error(UPNP_CONTROL_GET_VAR_COMPLETE): ";
+-		struct Upnp_State_Var_Complete *sv_event =
+-			(struct Upnp_State_Var_Complete *)Event;
+-		if (sv_event->ErrCode != UPNP_E_SUCCESS) {
++		UpnpStateVarComplete *sv_event = (UpnpStateVarComplete *)Event;
++		int errCode = UpnpStateVarComplete_get_ErrCode(sv_event);
++		if (errCode != UPNP_E_SUCCESS) {
+ 			msg << "m_UpnpGetServiceVarStatusAsync";
+ 			UPnP::ProcessErrorMessage(
+-				msg.str(), sv_event->ErrCode, NULL, NULL);
++				msg.str(), errCode, NULL, NULL);
+ 		} else {
+ #if 0
+ 			// Warning: The use of UpnpGetServiceVarStatus and
+ 			// UpnpGetServiceVarStatusAsync is deprecated by the
+ 			// UPnP forum.
++			const char *ctrlUrl =
++				UpnpStateVarComplete_get_CtrlUrl(sv_event);
++			const char *stateVarName =
++				UpnpStateVarComplete_get_StateVarName(sv_event);
++			const DOMString currentVal =
++				UpnpStateVarComplete_get_CurrentVal(sv_event);
+ 			TvCtrlPointHandleGetVar(
+-				sv_event->CtrlUrl,
+-				sv_event->StateVarName,
+-				sv_event->CurrentVal );
++				ctrlUrl, stateVarName, currentVal);
+ #endif
+ 		}
+ 		break;
+diff --git a/src/UPnPBase.h b/src/UPnPBase.h
+index 9eafbd143..92753b86a 100644
+--- a/src/UPnPBase.h
++++ b/src/UPnPBase.h
+@@ -489,9 +489,9 @@ public:
+ 
+ 	// Callback function
+ 	static int Callback(
+-		Upnp_EventType EventType,
+-		void* Event,
+-		void* Cookie);
++		Upnp_EventType_e EventType,
++		const void *Event,
++		void *Cookie);
+ 
+ private:
+ 	void OnEventReceived(
+-- 
+2.24.1
+

diff --git a/net-p2p/amule/files/amuled.confd-r1 b/net-p2p/amule/files/amuled.confd-r1
new file mode 100644
index 00000000000..2f018dd3b88
--- /dev/null
+++ b/net-p2p/amule/files/amuled.confd-r1
@@ -0,0 +1,9 @@
+# owner of amuled process (must be existing)
+AMULEUSER="amule"
+
+# home directory for amuled (must be existing)
+AMULEHOME="/var/lib/amule"
+
+# log file (/dev/null for nowhere)
+LOG=/var/log/amuled.log
+

diff --git a/net-p2p/amule/files/amuleweb.confd-r1 b/net-p2p/amule/files/amuleweb.confd-r1
new file mode 100644
index 00000000000..1bb754a2f04
--- /dev/null
+++ b/net-p2p/amule/files/amuleweb.confd-r1
@@ -0,0 +1,24 @@
+# owner of amuleweb process (must be existing)
+AMULEUSER="amule"
+
+# home directory for amuleweb (from where to read configuration) (must be existing)
+AMULEHOME="/var/lib/amule"
+
+# log file (/dev/null for nowhere)
+LOG=/var/log/amuleweb.log
+
+# aMule password (note: not your webserver password, but the external
+# connection one)
+AMULEPWD="secret"
+
+# Full (admin) access password for webserver
+WEBPWD="secret2"
+
+# aMule host (this could be a remote host or usually localhost)
+AMULEHOST="localhost"
+
+# aMule external connection port
+AMULEPORT="4712"
+
+# aMuleweb template (default, php-default, chicane)
+TEMPLATE="default"


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2020-02-20 13:27 Joonas Niilola
  0 siblings, 0 replies; 10+ messages in thread
From: Joonas Niilola @ 2020-02-20 13:27 UTC (permalink / raw
  To: gentoo-commits

commit:     2912503476a06505e0575648bdc85e1238ed17fd
Author:     Alexander Tsoy <alexander <AT> tsoy <DOT> me>
AuthorDate: Mon Feb  3 07:56:57 2020 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu Feb 20 13:17:20 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=29125034

net-p2p/amule: fix build with binutils-2.34

Closes: https://bugs.gentoo.org/707884
Signed-off-by: Alexander Tsoy <alexander <AT> tsoy.me>
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 net-p2p/amule/amule-2.3.2-r4.ebuild                |  1 +
 ...le-2.3.2-Fixed-compilation-with-newer-bfd.patch | 33 ++++++++++++++++++++++
 2 files changed, 34 insertions(+)

diff --git a/net-p2p/amule/amule-2.3.2-r4.ebuild b/net-p2p/amule/amule-2.3.2-r4.ebuild
index 8199a8471f0..eee88909130 100644
--- a/net-p2p/amule/amule-2.3.2-r4.ebuild
+++ b/net-p2p/amule/amule-2.3.2-r4.ebuild
@@ -45,6 +45,7 @@ PATCHES=(
 	"${FILESDIR}/${PN}-2.3.2-fix-crash-when-shared-files-changed.patch"
 	"${FILESDIR}/${PN}-2.3.2-libupnp-1.8.patch"
 	"${FILESDIR}/${PN}-2.3.2-libupnp-1.6.patch"
+	"${FILESDIR}/${PN}-2.3.2-Fixed-compilation-with-newer-bfd.patch"
 )
 
 pkg_setup() {

diff --git a/net-p2p/amule/files/amule-2.3.2-Fixed-compilation-with-newer-bfd.patch b/net-p2p/amule/files/amule-2.3.2-Fixed-compilation-with-newer-bfd.patch
new file mode 100644
index 00000000000..3ef8a21fa45
--- /dev/null
+++ b/net-p2p/amule/files/amule-2.3.2-Fixed-compilation-with-newer-bfd.patch
@@ -0,0 +1,33 @@
+From c0c28234a40b1b575ce51cdfe5ffa5dac3a7494c Mon Sep 17 00:00:00 2001
+From: Werner Mahr <werner@vollstreckernet.de>
+Date: Fri, 31 Jan 2020 17:55:24 +0100
+Subject: [PATCH] Fixed compilation with newer bfd. Fixes: #174
+
+---
+ src/libs/common/MuleDebug.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/libs/common/MuleDebug.cpp b/src/libs/common/MuleDebug.cpp
+index 5d8d75890..0ebf2ab07 100644
+--- a/src/libs/common/MuleDebug.cpp
++++ b/src/libs/common/MuleDebug.cpp
+@@ -268,14 +268,14 @@ void get_file_line_info(bfd *abfd, asection *section, void* _address)
+ 		return;
+ 	}
+ 
+-	bfd_vma vma = bfd_get_section_vma(abfd, section);
++	bfd_vma vma = section->vma;
+ 
+ 	unsigned long address = (unsigned long)_address;
+ 	if (address < vma) {
+ 		return;
+ 	}
+ 
+-	bfd_size_type size = bfd_section_size(abfd, section);
++	bfd_size_type size = section->size;
+ 	if (address > (vma + size)) {
+ 		return;
+ 	}
+-- 
+2.24.1
+


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2020-06-20 20:31 Thomas Deutschmann
  0 siblings, 0 replies; 10+ messages in thread
From: Thomas Deutschmann @ 2020-06-20 20:31 UTC (permalink / raw
  To: gentoo-commits

commit:     15e3808326e878e43468463d42465798bd263be8
Author:     Alexander Tsoy <alexander <AT> tsoy <DOT> me>
AuthorDate: Mon Jun 15 15:23:32 2020 +0000
Commit:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Sat Jun 20 20:30:49 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=15e38083

net-p2p/amule: Remove old revision

Signed-off-by: Alexander Tsoy <alexander <AT> tsoy.me>
Closes: https://github.com/gentoo/gentoo/pull/16261
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>

 net-p2p/amule/amule-2.3.2-r2.ebuild | 104 ------------------------------------
 net-p2p/amule/files/amuled.confd    |  12 -----
 net-p2p/amule/files/amuleweb.confd  |  27 ----------
 3 files changed, 143 deletions(-)

diff --git a/net-p2p/amule/amule-2.3.2-r2.ebuild b/net-p2p/amule/amule-2.3.2-r2.ebuild
deleted file mode 100644
index d94a14893ec..00000000000
--- a/net-p2p/amule/amule-2.3.2-r2.ebuild
+++ /dev/null
@@ -1,104 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-WX_GTK_VER="3.0"
-
-inherit wxwidgets user
-
-MY_P="${PN/m/M}-${PV}"
-S="${WORKDIR}/${MY_P}"
-
-DESCRIPTION="aMule, the all-platform eMule p2p client"
-HOMEPAGE="http://www.amule.org/"
-SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.xz"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~alpha amd64 ~arm ppc ppc64 ~sparc x86"
-IUSE="daemon debug geoip nls remote stats upnp +X"
-
-COMMON_DEPEND="
-	dev-libs/boost:=
-	dev-libs/crypto++:=
-	sys-libs/binutils-libs:0=
-	sys-libs/zlib
-	x11-libs/wxGTK:${WX_GTK_VER}[X?]
-	stats? ( media-libs/gd:=[jpeg,png] )
-	geoip? ( dev-libs/geoip )
-	upnp? ( net-libs/libupnp:* )
-	remote? ( media-libs/libpng:0= )
-	!net-p2p/imule"
-DEPEND="${COMMON_DEPEND}"
-RDEPEND="${COMMON_DEPEND}"
-
-PATCHES=(
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-shared-dir-utf8.patch"
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-1.patch"
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-2.patch"
-	"${FILESDIR}/${PN}-2.3.2-cryptopp-6.patch"
-	"${FILESDIR}/${PN}-2.3.2-disable-version-check.patch"
-)
-
-pkg_setup() {
-	if use stats && ! use X; then
-		einfo "Note: You would need both the X and stats USE flags"
-		einfo "to compile aMule Statistics GUI."
-		einfo "I will now compile console versions only."
-	fi
-
-	setup-wxwidgets
-}
-
-pkg_preinst() {
-	if use daemon || use remote; then
-		enewgroup p2p
-		enewuser p2p -1 -1 /home/p2p p2p
-	fi
-}
-
-src_configure() {
-	local myconf
-
-	if use X; then
-		use stats && myconf="${myconf}
-			--enable-wxcas
-			--enable-alc"
-		use remote && myconf="${myconf}
-			--enable-amule-gui"
-	else
-		myconf="
-			--disable-monolithic
-			--disable-amule-gui
-			--disable-wxcas
-			--disable-alc"
-	fi
-
-	econf \
-		--with-denoise-level=0 \
-		--with-wx-config="${WX_CONFIG}" \
-		--enable-amulecmd \
-		--with-boost \
-		$(use_enable debug) \
-		$(use_enable daemon amule-daemon) \
-		$(use_enable geoip) \
-		$(use_enable nls) \
-		$(use_enable remote webserver) \
-		$(use_enable stats cas) \
-		$(use_enable stats alcc) \
-		$(use_enable upnp) \
-		${myconf}
-}
-
-src_install() {
-	default
-
-	if use daemon; then
-		newconfd "${FILESDIR}"/amuled.confd amuled
-		newinitd "${FILESDIR}"/amuled.initd amuled
-	fi
-	if use remote; then
-		newconfd "${FILESDIR}"/amuleweb.confd amuleweb
-		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
-	fi
-}

diff --git a/net-p2p/amule/files/amuled.confd b/net-p2p/amule/files/amuled.confd
deleted file mode 100644
index f8888bf2a2b..00000000000
--- a/net-p2p/amule/files/amuled.confd
+++ /dev/null
@@ -1,12 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-# owner of amuled process (must be existing)
-AMULEUSER="p2p"
-
-# home directory for amuled (must be existing)
-AMULEHOME="/home/p2p"
-
-# log file (/dev/null for nowhere)
-LOG=/var/log/amuled.log
-

diff --git a/net-p2p/amule/files/amuleweb.confd b/net-p2p/amule/files/amuleweb.confd
deleted file mode 100644
index 29a3ea62475..00000000000
--- a/net-p2p/amule/files/amuleweb.confd
+++ /dev/null
@@ -1,27 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-# owner of amuleweb process (must be existing)
-AMULEUSER="p2p"
-
-# home directory for amuleweb (from where to read configuration) (must be existing)
-AMULEHOME="/home/p2p"
-
-# log file (/dev/null for nowhere)
-LOG=/var/log/amuleweb.log
-
-# aMule password (note: not your webserver password, but the external
-# connection one)
-AMULEPWD="secret"
-
-# Full (admin) access password for webserver
-WEBPWD="secret2"
-
-# aMule host (this could be a remote host or usually localhost)
-AMULEHOST="localhost"
-
-# aMule external connection port
-AMULEPORT="4712"
-
-# aMuleweb template (default, php-default, chicane)
-TEMPLATE="default"


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2020-09-03 11:40 Hanno Böck
  0 siblings, 0 replies; 10+ messages in thread
From: Hanno Böck @ 2020-09-03 11:40 UTC (permalink / raw
  To: gentoo-commits

commit:     4dc57685e11b9b63789f531bf7414e23a84a9a25
Author:     Hanno Böck <hanno <AT> gentoo <DOT> org>
AuthorDate: Thu Sep  3 11:40:49 2020 +0000
Commit:     Hanno Böck <hanno <AT> gentoo <DOT> org>
CommitDate: Thu Sep  3 11:40:49 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4dc57685

net-p2p/amule: Fix compilation with libupnp 1.14.

Patch includes 2 upstream commits.

Closes: https://bugs.gentoo.org/740196
Signed-off-by: Hanno Böck <hanno <AT> gentoo.org>
Package-Manager: Portage-3.0.5, Repoman-3.0.1

 net-p2p/amule/amule-2.3.2-r5.ebuild                |  1 +
 net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch | 24 ++++++++++++++++++++++
 2 files changed, 25 insertions(+)

diff --git a/net-p2p/amule/amule-2.3.2-r5.ebuild b/net-p2p/amule/amule-2.3.2-r5.ebuild
index c35014cef8c..30856b93017 100644
--- a/net-p2p/amule/amule-2.3.2-r5.ebuild
+++ b/net-p2p/amule/amule-2.3.2-r5.ebuild
@@ -59,6 +59,7 @@ PATCHES=(
 	"${FILESDIR}/${PN}-2.3.2-libupnp-1.6.patch"
 	"${FILESDIR}/${PN}-2.3.2-Fixed-compilation-with-newer-bfd.patch"
 	"${FILESDIR}/${PN}-2.3.2-desktop-mimetype.patch"
+	"${FILESDIR}/${PN}-2.3.2-libupnp-1.14.patch"
 )
 
 pkg_setup() {

diff --git a/net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch b/net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch
new file mode 100644
index 00000000000..d68e4776e0a
--- /dev/null
+++ b/net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch
@@ -0,0 +1,24 @@
+--- a/src/UPnPBase.cpp	2016-09-16 09:55:07.000000000 +0200
++++ b/src/UPnPBase.cpp	2020-09-03 12:37:43.861231093 +0200
+@@ -824,13 +824,17 @@ m_WanService(NULL)
+ 	// Null string at first
+ 	std::ostringstream msg;
+ 
++	// Declare those here to avoid 
++	// "jump to label ‘error’ [-fpermissive] crosses initialization
++	// of ‘char* ipAddress’"
++	unsigned short port;
++	char *ipAddress;
++
+ 	// Start UPnP
+ 	int ret;
+-	char *ipAddress = NULL;
+-	unsigned short port = 0;
+-	ret = UpnpInit(ipAddress, udpPort);
++	ret = UpnpInit2(0, udpPort);
+ 	if (ret != UPNP_E_SUCCESS) {
+-		msg << "error(UpnpInit): Error code ";
++		msg << "error(UpnpInit2): Error code ";
+ 		goto error;
+ 	}
+ 	port = UpnpGetServerPort();


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2021-06-21 22:26 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2021-06-21 22:26 UTC (permalink / raw
  To: gentoo-commits

commit:     c7d1e42950960a4cea26c5cd727dc3f40b45d6de
Author:     Alexander Tsoy <alexander <AT> tsoy <DOT> me>
AuthorDate: Sun Jun 20 18:25:43 2021 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Jun 21 22:26:05 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c7d1e429

net-p2p/amule: Remove old

Signed-off-by: Alexander Tsoy <alexander <AT> tsoy.me>
Closes: https://github.com/gentoo/gentoo/pull/21348
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-p2p/amule/Manifest                             |   1 -
 net-p2p/amule/amule-2.3.2-r5.ebuild                | 155 ---------
 ...le-2.3.2-Fixed-compilation-with-newer-bfd.patch |  33 --
 net-p2p/amule/files/amule-2.3.2-cryptopp-6.patch   |  25 --
 .../amule/files/amule-2.3.2-desktop-mimetype.patch |  30 --
 ...2.3.2-fix-crash-closing-last-search-tab-1.patch |  97 ------
 ...2.3.2-fix-crash-closing-last-search-tab-2.patch | 159 ----------
 .../amule-2.3.2-fix-crash-shared-dir-utf8.patch    |  78 -----
 ...2.3.2-fix-crash-when-shared-files-changed.patch |  50 ---
 net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch |  24 --
 net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch  | 350 ---------------------
 net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch  | 263 ----------------
 12 files changed, 1265 deletions(-)

diff --git a/net-p2p/amule/Manifest b/net-p2p/amule/Manifest
index 83f4b988336..0b9d01e1aa4 100644
--- a/net-p2p/amule/Manifest
+++ b/net-p2p/amule/Manifest
@@ -1,2 +1 @@
-DIST aMule-2.3.2.tar.xz 3895300 BLAKE2B cf1bce3a0fcd0c108e369b7aed257f067a4ce3ce2fd4e8509b577ac58f8bc52fbc9aabc5c703bc9111dd06ac011ee1f3756279b093b69bcaada106226493237a SHA512 3064b086f8459b4372ea0c11f239a08167c7beac3dde26889f056f617b480b487bea10c2cae8fdfa1ae99c10fc9e715adc8e01e4b968389861aa47c3ec8c0016
 DIST aMule-2.3.3.tar.xz 3699376 BLAKE2B 4b1fb98bd52e4c75f81773020d4fc258f8e7c4d7a5d40a7aadabc8fd27b3079705761650fdcd7cd089da77575a74f1950f02039ee14bf4b9894550b8b3d9191b SHA512 a5a80c5ddd1e107d92070c1d8e232c2762c4c54791abc067c739eef7c690062ed164dd7733808f80c762719261162aeb3d602308964dda2670a0bb059d87b74e

diff --git a/net-p2p/amule/amule-2.3.2-r5.ebuild b/net-p2p/amule/amule-2.3.2-r5.ebuild
deleted file mode 100644
index 30856b93017..00000000000
--- a/net-p2p/amule/amule-2.3.2-r5.ebuild
+++ /dev/null
@@ -1,155 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-WX_GTK_VER="3.0-gtk3"
-
-inherit wxwidgets xdg-utils
-
-if [[ ${PV} == 9999 ]] ; then
-	EGIT_REPO_URI="https://github.com/amule-project/amule"
-	inherit autotools git-r3
-else
-	MY_P="${PN/m/M}-${PV}"
-	SRC_URI="https://download.sourceforge.net/${PN}/${MY_P}.tar.xz"
-	S="${WORKDIR}/${MY_P}"
-	KEYWORDS="~alpha amd64 ~arm ppc ppc64 ~sparc x86"
-fi
-
-DESCRIPTION="aMule, the all-platform eMule p2p client"
-HOMEPAGE="http://www.amule.org/"
-
-LICENSE="GPL-2+"
-SLOT="0"
-IUSE="daemon debug geoip nls remote stats upnp +X"
-
-RDEPEND="
-	dev-libs/boost:=
-	dev-libs/crypto++:=
-	sys-libs/binutils-libs:0=
-	sys-libs/readline:0=
-	sys-libs/zlib
-	>=x11-libs/wxGTK-3.0.4:${WX_GTK_VER}[X?]
-	daemon? ( acct-user/amule )
-	geoip? ( dev-libs/geoip )
-	nls? ( virtual/libintl )
-	remote? (
-		acct-user/amule
-		media-libs/libpng:0=
-	)
-	stats? ( media-libs/gd:=[jpeg,png] )
-	upnp? ( net-libs/libupnp:0 )
-"
-DEPEND="${RDEPEND}
-	X? ( dev-util/desktop-file-utils )
-"
-BDEPEND="
-	virtual/pkgconfig
-	nls? ( sys-devel/gettext )
-"
-
-PATCHES=(
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-shared-dir-utf8.patch"
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-1.patch"
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-closing-last-search-tab-2.patch"
-	"${FILESDIR}/${PN}-2.3.2-cryptopp-6.patch"
-	"${FILESDIR}/${PN}-2.3.2-disable-version-check.patch"
-	"${FILESDIR}/${PN}-2.3.2-fix-crash-when-shared-files-changed.patch"
-	"${FILESDIR}/${PN}-2.3.2-libupnp-1.8.patch"
-	"${FILESDIR}/${PN}-2.3.2-libupnp-1.6.patch"
-	"${FILESDIR}/${PN}-2.3.2-Fixed-compilation-with-newer-bfd.patch"
-	"${FILESDIR}/${PN}-2.3.2-desktop-mimetype.patch"
-	"${FILESDIR}/${PN}-2.3.2-libupnp-1.14.patch"
-)
-
-pkg_setup() {
-	setup-wxwidgets
-}
-
-src_prepare() {
-	default
-
-	if [[ ${PV} == 9999 ]]; then
-		./autogen.sh || die
-	fi
-}
-
-src_configure() {
-	local myconf=(
-		--with-denoise-level=0
-		--with-wx-config="${WX_CONFIG}"
-		--enable-amulecmd
-		--with-boost
-		$(use_enable debug)
-		$(use_enable daemon amule-daemon)
-		$(use_enable geoip)
-		$(use_enable nls)
-		$(use_enable remote webserver)
-		$(use_enable stats cas)
-		$(use_enable stats alcc)
-		$(use_enable upnp)
-	)
-
-	if use X; then
-		myconf+=(
-			$(use_enable remote amule-gui)
-			$(use_enable stats alc)
-			$(use_enable stats wxcas)
-		)
-	else
-		myconf+=(
-			--disable-monolithic
-			--disable-amule-gui
-			--disable-alc
-			--disable-wxcas
-		)
-	fi
-
-	econf "${myconf[@]}"
-}
-
-src_install() {
-	default
-
-	if use daemon; then
-		newconfd "${FILESDIR}"/amuled.confd-r1 amuled
-		newinitd "${FILESDIR}"/amuled.initd amuled
-	fi
-	if use remote; then
-		newconfd "${FILESDIR}"/amuleweb.confd-r1 amuleweb
-		newinitd "${FILESDIR}"/amuleweb.initd amuleweb
-	fi
-
-	if use daemon || use remote; then
-		keepdir /var/lib/${PN}
-		fowners amule:amule /var/lib/${PN}
-		fperms 0750 /var/lib/${PN}
-	fi
-}
-
-pkg_postinst() {
-	local ver
-
-	if use daemon || use remote; then
-		for ver in ${REPLACING_VERSIONS}; do
-			if ver_test ${ver} -lt "2.3.2-r4"; then
-				elog "Default user under which amuled and amuleweb daemons are started"
-				elog "have been changed from p2p to amule. Default home directory have been"
-				elog "changed as well."
-				echo
-				elog "If you want to preserve old download/share location, you can create"
-				elog "symlink /var/lib/amule/.aMule pointing to the old location and adjust"
-				elog "files ownership *or* restore AMULEUSER and AMULEHOME variables in"
-				elog "/etc/conf.d/{amuled,amuleweb} to the old values."
-
-				break
-			fi
-		done
-	fi
-
-	use X && xdg_desktop_database_update
-}
-
-pkg_postrm() {
-	use X && xdg_desktop_database_update
-}

diff --git a/net-p2p/amule/files/amule-2.3.2-Fixed-compilation-with-newer-bfd.patch b/net-p2p/amule/files/amule-2.3.2-Fixed-compilation-with-newer-bfd.patch
deleted file mode 100644
index 3ef8a21fa45..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-Fixed-compilation-with-newer-bfd.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From c0c28234a40b1b575ce51cdfe5ffa5dac3a7494c Mon Sep 17 00:00:00 2001
-From: Werner Mahr <werner@vollstreckernet.de>
-Date: Fri, 31 Jan 2020 17:55:24 +0100
-Subject: [PATCH] Fixed compilation with newer bfd. Fixes: #174
-
----
- src/libs/common/MuleDebug.cpp | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/libs/common/MuleDebug.cpp b/src/libs/common/MuleDebug.cpp
-index 5d8d75890..0ebf2ab07 100644
---- a/src/libs/common/MuleDebug.cpp
-+++ b/src/libs/common/MuleDebug.cpp
-@@ -268,14 +268,14 @@ void get_file_line_info(bfd *abfd, asection *section, void* _address)
- 		return;
- 	}
- 
--	bfd_vma vma = bfd_get_section_vma(abfd, section);
-+	bfd_vma vma = section->vma;
- 
- 	unsigned long address = (unsigned long)_address;
- 	if (address < vma) {
- 		return;
- 	}
- 
--	bfd_size_type size = bfd_section_size(abfd, section);
-+	bfd_size_type size = section->size;
- 	if (address > (vma + size)) {
- 		return;
- 	}
--- 
-2.24.1
-

diff --git a/net-p2p/amule/files/amule-2.3.2-cryptopp-6.patch b/net-p2p/amule/files/amule-2.3.2-cryptopp-6.patch
deleted file mode 100644
index d2353447560..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-cryptopp-6.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 27c13f3e622b8a3eaaa05bb62b0149604bdcc9e8 Mon Sep 17 00:00:00 2001
-From: Tommy Jerry Mairo <tommy.mairo@gmail.com>
-Date: Wed, 21 Mar 2018 19:56:28 +0100
-Subject: [PATCH] Bugfix: API mismatch with crypto++ 6.0.0
-
----
- src/ClientCreditsList.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/ClientCreditsList.cpp b/src/ClientCreditsList.cpp
-index 3bea9fe2d..69e881fd8 100644
---- a/src/ClientCreditsList.cpp
-+++ b/src/ClientCreditsList.cpp
-@@ -312,7 +312,7 @@ void CClientCreditsList::InitalizeCrypting()
- 		// calculate and store public key
- 		CryptoPP::RSASSA_PKCS1v15_SHA_Verifier pubkey(*static_cast<CryptoPP::RSASSA_PKCS1v15_SHA_Signer *>(m_pSignkey));
- 		CryptoPP::ArraySink asink(m_abyMyPublicKey, 80);
--		pubkey.DEREncode(asink);
-+		pubkey.GetMaterial().Save(asink);
- 		m_nMyPublicKeyLen = asink.TotalPutLength();
- 		asink.MessageEnd();
- 	} catch (const CryptoPP::Exception& e) {
--- 
-2.16.4
-

diff --git a/net-p2p/amule/files/amule-2.3.2-desktop-mimetype.patch b/net-p2p/amule/files/amule-2.3.2-desktop-mimetype.patch
deleted file mode 100644
index cd8ba4c2fc5..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-desktop-mimetype.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 048e86d44e09ef9dc1897c432660a712109b263a Mon Sep 17 00:00:00 2001
-From: Werner Mahr <werner@vollstreckernet.de>
-Date: Mon, 29 Apr 2019 18:37:35 +0200
-Subject: [PATCH] Added imetype-handler for amule ed2k-links. Patch taken from
- debian.
-
----
- amule.desktop | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/amule.desktop b/amule.desktop
-index 70be367af..1cfb38010 100644
---- a/amule.desktop
-+++ b/amule.desktop
-@@ -1,6 +1,6 @@
- [Desktop Entry]
- Name=aMule
--Exec=amule
-+Exec=amule %u
- Icon=amule
- Terminal=false
- Type=Application
-@@ -8,3 +8,4 @@ Categories=Network;P2P;
- Comment=A client for the eD2k network
- Comment[fr]=Un client pour le réseau eD2k
- Comment[tr]=eD2k ağı için istemci
-+MimeType=x-scheme-handler/ed2k;
--- 
-2.26.2
-

diff --git a/net-p2p/amule/files/amule-2.3.2-fix-crash-closing-last-search-tab-1.patch b/net-p2p/amule/files/amule-2.3.2-fix-crash-closing-last-search-tab-1.patch
deleted file mode 100644
index c480165eb98..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-fix-crash-closing-last-search-tab-1.patch
+++ /dev/null
@@ -1,97 +0,0 @@
-From 0f0c5c220228aea81142c7c00f73414cdb1b507a Mon Sep 17 00:00:00 2001
-From: gaffa <gaffa@confuseacat.dk>
-Date: Wed, 12 Oct 2016 19:36:21 +0200
-Subject: [PATCH] A workaround for inconsistent behaviour in wxWidgets, where
- the button release signal is falling through. Instead of calling DeletePage
- directly an event is added to delete the page after the button release event
- has been processed by all handlers.
-
----
- src/MuleNotebook.cpp | 17 ++++++++++++++++-
- src/MuleNotebook.h   | 13 +++++++++++++
- 2 files changed, 29 insertions(+), 1 deletion(-)
-
-diff --git a/src/MuleNotebook.cpp b/src/MuleNotebook.cpp
-index ff3ba294e..4ab23ce18 100644
---- a/src/MuleNotebook.cpp
-+++ b/src/MuleNotebook.cpp
-@@ -32,6 +32,7 @@
- 
- DEFINE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_PAGE_CLOSING)
- DEFINE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_ALL_PAGES_CLOSED)
-+DEFINE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE)
- 
- BEGIN_EVENT_TABLE(CMuleNotebook, wxNotebook)
- 	EVT_RIGHT_DOWN(CMuleNotebook::OnRMButton)
-@@ -44,6 +45,7 @@ BEGIN_EVENT_TABLE(CMuleNotebook, wxNotebook)
- 	EVT_LEFT_UP(CMuleNotebook::OnMouseButtonRelease)
- 	EVT_MIDDLE_UP(CMuleNotebook::OnMouseButtonRelease)
- 	EVT_MOTION(CMuleNotebook::OnMouseMotion)
-+	EVT_MULENOTEBOOK_DELETE_PAGE(wxID_ANY, CMuleNotebook::OnDeletePage)
- END_EVENT_TABLE()
- 
- CMuleNotebook::CMuleNotebook( wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name )
-@@ -60,6 +62,12 @@ CMuleNotebook::~CMuleNotebook()
- 	DeleteAllPages();
- }
- 
-+void CMuleNotebook::OnDeletePage(wxBookCtrlEvent& evt)
-+{
-+	int page = evt.GetSelection();
-+	DeletePage(page);
-+}
-+
- 
- bool CMuleNotebook::DeletePage(int nPage)
- {
-@@ -216,7 +224,14 @@ void CMuleNotebook::OnMouseButtonRelease(wxMouseEvent &event)
- 	if ((tab != -1) &&  (((flags == wxNB_HITTEST_ONICON) && event.LeftUp()) ||
- 			((flags == wxNB_HITTEST_ONLABEL) && event.MiddleUp()))) {
- 		// User did click on a 'x' or middle click on the label
--		DeletePage(tab);
-+
-+		/*	WORKAROUND: Instead of calling DeletePage, we need to wait for the
-+		 *	mouse release signal to reach Gtk. Inconsistent with normal wxEvent
-+		 *	behaviour the button release handler in wxWidgets don't evaluate
-+		 *	the result of the signal handling. */
-+		wxNotebookEvent evt( wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE, GetId(), tab );
-+		evt.SetEventObject(this);
-+		AddPendingEvent( evt );
- 	} else {
- 		// Is not a 'x'. Send this event up.
- 		event.Skip();
-diff --git a/src/MuleNotebook.h b/src/MuleNotebook.h
-index dda097d07..ab2809d88 100644
---- a/src/MuleNotebook.h
-+++ b/src/MuleNotebook.h
-@@ -31,7 +31,16 @@
- 
- DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_PAGE_CLOSING, -1)
- DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_ALL_PAGES_CLOSED, -1)
-+DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE, -1)
- 
-+#define EVT_MULENOTEBOOK_DELETE_PAGE(id, fn)						\
-+	DECLARE_EVENT_TABLE_ENTRY(							\
-+		wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE,					\
-+		id,									\
-+		-1,									\
-+		(wxObjectEventFunction)(wxEventFunction)(wxNotebookEventFunction) &fn,  \
-+		NULL                                                                    \
-+	),
- #define EVT_MULENOTEBOOK_PAGE_CLOSING(id, fn)						\
- 	DECLARE_EVENT_TABLE_ENTRY(							\
- 		wxEVT_COMMAND_MULENOTEBOOK_PAGE_CLOSING,					\
-@@ -107,6 +116,10 @@ public:
- 	 */
- 	void SetPopupHandler( wxWindow* widget );
- 
-+private:
-+	// Internal handler. Workaround for wxWidgets Tab-Crash bug.
-+	void OnDeletePage(wxBookCtrlEvent& evt);
-+
- protected:
- 	/**
- 	 * Event handler for left or middle mouse button release (for closing pages)
--- 
-2.16.4
-

diff --git a/net-p2p/amule/files/amule-2.3.2-fix-crash-closing-last-search-tab-2.patch b/net-p2p/amule/files/amule-2.3.2-fix-crash-closing-last-search-tab-2.patch
deleted file mode 100644
index e47970beb0c..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-fix-crash-closing-last-search-tab-2.patch
+++ /dev/null
@@ -1,159 +0,0 @@
-From 4c94c2d9f3be8b9068966f15aebc29b8c9b706ab Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?D=C3=A9vai=20Tam=C3=A1s?= <gonosztopi@amule.org>
-Date: Mon, 17 Oct 2016 22:14:26 +0200
-Subject: [PATCH] Apply the workaround only if needed
-
-This way it'll be easy for us to remove the workaround once wxWidgets fixes
-the bug.
----
- docs/Changelog       |  4 ++++
- src/MuleNotebook.cpp | 19 ++++++++++++++-----
- src/MuleNotebook.h   |  8 ++++++++
- 3 files changed, 26 insertions(+), 5 deletions(-)
-
-diff --git a/docs/Changelog b/docs/Changelog
-index 7dbff70b2..e9176dd51 100644
---- a/docs/Changelog
-+++ b/docs/Changelog
-@@ -2,6 +2,10 @@ Version 2.4.0 - The river knows.
- ----------
- 201?-??-??
- 
-+	gaffatape:
-+		* Workaround for bug in wxWidgets causing aMule to crash on
-+		  closing the last search tab
-+
- 	GonoszTopi:
- 		* Fix restoring toolbar orientation on 'Cancel'
- 
-diff --git a/src/MuleNotebook.cpp b/src/MuleNotebook.cpp
-index 4ab23ce18..5d3ad0453 100644
---- a/src/MuleNotebook.cpp
-+++ b/src/MuleNotebook.cpp
-@@ -32,7 +32,10 @@
- 
- DEFINE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_PAGE_CLOSING)
- DEFINE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_ALL_PAGES_CLOSED)
-+
-+#if MULE_NEEDS_DELETEPAGE_WORKAROUND
- DEFINE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE)
-+#endif
- 
- BEGIN_EVENT_TABLE(CMuleNotebook, wxNotebook)
- 	EVT_RIGHT_DOWN(CMuleNotebook::OnRMButton)
-@@ -45,9 +48,12 @@ BEGIN_EVENT_TABLE(CMuleNotebook, wxNotebook)
- 	EVT_LEFT_UP(CMuleNotebook::OnMouseButtonRelease)
- 	EVT_MIDDLE_UP(CMuleNotebook::OnMouseButtonRelease)
- 	EVT_MOTION(CMuleNotebook::OnMouseMotion)
-+#if MULE_NEEDS_DELETEPAGE_WORKAROUND
- 	EVT_MULENOTEBOOK_DELETE_PAGE(wxID_ANY, CMuleNotebook::OnDeletePage)
-+#endif
- END_EVENT_TABLE()
- 
-+
- CMuleNotebook::CMuleNotebook( wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name )
- 	: wxNotebook(parent, id, pos, size, style, name)
- {
-@@ -62,11 +68,14 @@ CMuleNotebook::~CMuleNotebook()
- 	DeleteAllPages();
- }
- 
-+
-+#if MULE_NEEDS_DELETEPAGE_WORKAROUND
- void CMuleNotebook::OnDeletePage(wxBookCtrlEvent& evt)
- {
- 	int page = evt.GetSelection();
- 	DeletePage(page);
- }
-+#endif // MULE_NEEDS_DELETEPAGE_WORKAROUND
- 
- 
- bool CMuleNotebook::DeletePage(int nPage)
-@@ -208,7 +217,6 @@ void CMuleNotebook::OnPopupCloseOthers(wxCommandEvent& WXUNUSED(evt))
- 
- void CMuleNotebook::OnMouseButtonRelease(wxMouseEvent &event)
- {
--
- 	if (GetImageList() == NULL) {
- 		// This Mulenotebook has no images on tabs, so nothing to do.
- 		event.Skip();
-@@ -224,7 +232,7 @@ void CMuleNotebook::OnMouseButtonRelease(wxMouseEvent &event)
- 	if ((tab != -1) &&  (((flags == wxNB_HITTEST_ONICON) && event.LeftUp()) ||
- 			((flags == wxNB_HITTEST_ONLABEL) && event.MiddleUp()))) {
- 		// User did click on a 'x' or middle click on the label
--
-+#if MULE_NEEDS_DELETEPAGE_WORKAROUND
- 		/*	WORKAROUND: Instead of calling DeletePage, we need to wait for the
- 		 *	mouse release signal to reach Gtk. Inconsistent with normal wxEvent
- 		 *	behaviour the button release handler in wxWidgets don't evaluate
-@@ -232,16 +240,18 @@ void CMuleNotebook::OnMouseButtonRelease(wxMouseEvent &event)
- 		wxNotebookEvent evt( wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE, GetId(), tab );
- 		evt.SetEventObject(this);
- 		AddPendingEvent( evt );
-+#else
-+		DeletePage(tab);
-+#endif // MULE_NEEDS_DELETEPAGE_WORKAROUND
- 	} else {
- 		// Is not a 'x'. Send this event up.
- 		event.Skip();
- 	}
--
- }
- 
-+
- void CMuleNotebook::OnMouseMotion(wxMouseEvent &event)
- {
--
- 	if (GetImageList() == NULL) {
- 		// This Mulenotebook has no images on tabs, so nothing to do.
- 		event.Skip();
-@@ -263,7 +273,6 @@ void CMuleNotebook::OnMouseMotion(wxMouseEvent &event)
- 		// Is not a 'x'. Send this event up.
- 		event.Skip();
- 	}
--
- }
- 
- // File_checked_for_headers
-diff --git a/src/MuleNotebook.h b/src/MuleNotebook.h
-index ab2809d88..14f61ee68 100644
---- a/src/MuleNotebook.h
-+++ b/src/MuleNotebook.h
-@@ -28,9 +28,13 @@
- 
- #include <wx/notebook.h>
- 
-+#define MULE_NEEDS_DELETEPAGE_WORKAROUND	wxCHECK_VERSION(3,0,2)
-+
- 
- DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_PAGE_CLOSING, -1)
- DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_ALL_PAGES_CLOSED, -1)
-+
-+#if MULE_NEEDS_DELETEPAGE_WORKAROUND
- DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE, -1)
- 
- #define EVT_MULENOTEBOOK_DELETE_PAGE(id, fn)						\
-@@ -41,6 +45,8 @@ DECLARE_LOCAL_EVENT_TYPE(wxEVT_COMMAND_MULENOTEBOOK_DELETE_PAGE, -1)
- 		(wxObjectEventFunction)(wxEventFunction)(wxNotebookEventFunction) &fn,  \
- 		NULL                                                                    \
- 	),
-+#endif // MULE_NEEDS_DELETEPAGE_WORKAROUND
-+
- #define EVT_MULENOTEBOOK_PAGE_CLOSING(id, fn)						\
- 	DECLARE_EVENT_TABLE_ENTRY(							\
- 		wxEVT_COMMAND_MULENOTEBOOK_PAGE_CLOSING,					\
-@@ -116,9 +122,11 @@ public:
- 	 */
- 	void SetPopupHandler( wxWindow* widget );
- 
-+#if MULE_NEEDS_DELETEPAGE_WORKAROUND
- private:
- 	// Internal handler. Workaround for wxWidgets Tab-Crash bug.
- 	void OnDeletePage(wxBookCtrlEvent& evt);
-+#endif // MULE_NEEDS_DELETEPAGE_WORKAROUND
- 
- protected:
- 	/**
--- 
-2.16.4
-

diff --git a/net-p2p/amule/files/amule-2.3.2-fix-crash-shared-dir-utf8.patch b/net-p2p/amule/files/amule-2.3.2-fix-crash-shared-dir-utf8.patch
deleted file mode 100644
index aa92ff6c81e..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-fix-crash-shared-dir-utf8.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-From 17816ed02f59bab9c27310e7f24c73266b0a3003 Mon Sep 17 00:00:00 2001
-From: persmule <persmule@gmail.com>
-Date: Wed, 5 Oct 2016 13:47:46 +0800
-Subject: [PATCH] Add a routine to set file name conversion for amuled which
- based on wxAppConsole
-
----
- src/amule.h    |  7 +++++++
- src/amuled.cpp | 35 +++++++++++++++++++++++++++++++++++
- 2 files changed, 42 insertions(+)
-
-diff --git a/src/amule.h b/src/amule.h
-index f25702f60..240c02dd9 100644
---- a/src/amule.h
-+++ b/src/amule.h
-@@ -553,6 +553,13 @@ private:
- 	int OnExit();
- 
- 	virtual int InitGui(bool geometry_enable, wxString &geometry_string);
-+	// The GTK wxApps sets its file name conversion properly
-+	// in wxApp::Initialize(), while wxAppConsole::Initialize()
-+	// does not, leaving wxConvFile being set to wxConvLibc. File
-+	// name conversion should be set otherwise amuled will abort to
-+	// handle non-ASCII file names which monolithic amule can handle.
-+	// This function are overrided to perform this.
-+	virtual bool Initialize(int& argc_, wxChar **argv_);
- 
- #ifdef AMULED_APPTRAITS
- 	struct sigaction m_oldSignalChildAction;
-diff --git a/src/amuled.cpp b/src/amuled.cpp
-index 486da5973..86e1ff8b8 100644
---- a/src/amuled.cpp
-+++ b/src/amuled.cpp
-@@ -704,6 +704,41 @@ int CamuleDaemonApp::InitGui(bool ,wxString &)
- 	return 0;
- }
- 
-+bool CamuleDaemonApp::Initialize(int& argc_, wxChar **argv_)
-+{
-+	if ( !wxAppConsole::Initialize(argc_, argv_) ) {
-+		return false;
-+	}
-+
-+#ifdef __UNIX__
-+	wxString encName;
-+#if wxUSE_INTL
-+	// if a non default locale is set,
-+	// assume that the user wants his
-+        // filenames in this locale too
-+        encName = wxLocale::GetSystemEncodingName().Upper();
-+
-+        // But don't consider ASCII in this case.
-+	if ( !encName.empty() ) {
-+		if ( encName == wxT("US-ASCII") ) {
-+			// This means US-ASCII when returned
-+			// from GetEncodingFromName().
-+			encName.clear();
-+		}
-+        }
-+#endif // wxUSE_INTL
-+
-+	// in this case, UTF-8 is used by default.
-+        if ( encName.empty() ) {
-+		encName = wxT("UTF-8");
-+	}
-+
-+	static wxConvBrokenFileNames fileconv(encName);
-+	wxConvFileName = &fileconv;
-+#endif // __UNIX__
-+
-+	return true;
-+}
- 
- int CamuleDaemonApp::OnExit()
- {
--- 
-2.16.4
-

diff --git a/net-p2p/amule/files/amule-2.3.2-fix-crash-when-shared-files-changed.patch b/net-p2p/amule/files/amule-2.3.2-fix-crash-when-shared-files-changed.patch
deleted file mode 100644
index 81e0ef7b629..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-fix-crash-when-shared-files-changed.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 110a056fa4bcfc0fe8c1f8eadcc2bd5df0bbf5e1 Mon Sep 17 00:00:00 2001
-From: xinhuang <xinhuang.abc@gmail.com>
-Date: Thu, 4 Jan 2018 00:44:35 -0800
-Subject: [PATCH] fix crash when shared files changed on Shared files tab
-
----
- src/extern/wxWidgets/listctrl.cpp | 10 ----------
- src/extern/wxWidgets/listctrl.h   |  5 -----
- 2 files changed, 15 deletions(-)
-
-diff --git a/src/extern/wxWidgets/listctrl.cpp b/src/extern/wxWidgets/listctrl.cpp
-index 18a30f205..460700691 100644
---- a/src/extern/wxWidgets/listctrl.cpp
-+++ b/src/extern/wxWidgets/listctrl.cpp
-@@ -5803,16 +5803,6 @@ bool wxGenericListCtrl::DoPopupMenu( wxMenu *menu, int x, int y )
- #endif
- }
- 
--void wxGenericListCtrl::DoClientToScreen( int *x, int *y ) const
--{
--    m_mainWin->DoClientToScreen(x, y);
--}
--
--void wxGenericListCtrl::DoScreenToClient( int *x, int *y ) const
--{
--    m_mainWin->DoScreenToClient(x, y);
--}
--
- void wxGenericListCtrl::SetFocus()
- {
-     // The test in window.cpp fails as we are a composite
-diff --git a/src/extern/wxWidgets/listctrl.h b/src/extern/wxWidgets/listctrl.h
-index b18a61866..e72f7eaf0 100644
---- a/src/extern/wxWidgets/listctrl.h
-+++ b/src/extern/wxWidgets/listctrl.h
-@@ -232,11 +232,6 @@ public:
- protected:
-     virtual bool DoPopupMenu( wxMenu *menu, int x, int y );
- 
--    // take into account the coordinates difference between the container
--    // window and the list control window itself here
--    virtual void DoClientToScreen( int *x, int *y ) const;
--    virtual void DoScreenToClient( int *x, int *y ) const;
--
-     virtual wxSize DoGetBestSize() const;
- 
-     // return the text for the given column of the given item
--- 
-2.21.0
-

diff --git a/net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch b/net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch
deleted file mode 100644
index d68e4776e0a..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-libupnp-1.14.patch
+++ /dev/null
@@ -1,24 +0,0 @@
---- a/src/UPnPBase.cpp	2016-09-16 09:55:07.000000000 +0200
-+++ b/src/UPnPBase.cpp	2020-09-03 12:37:43.861231093 +0200
-@@ -824,13 +824,17 @@ m_WanService(NULL)
- 	// Null string at first
- 	std::ostringstream msg;
- 
-+	// Declare those here to avoid 
-+	// "jump to label ‘error’ [-fpermissive] crosses initialization
-+	// of ‘char* ipAddress’"
-+	unsigned short port;
-+	char *ipAddress;
-+
- 	// Start UPnP
- 	int ret;
--	char *ipAddress = NULL;
--	unsigned short port = 0;
--	ret = UpnpInit(ipAddress, udpPort);
-+	ret = UpnpInit2(0, udpPort);
- 	if (ret != UPNP_E_SUCCESS) {
--		msg << "error(UpnpInit): Error code ";
-+		msg << "error(UpnpInit2): Error code ";
- 		goto error;
- 	}
- 	port = UpnpGetServerPort();

diff --git a/net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch b/net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch
deleted file mode 100644
index 0fd0edfbd8f..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-libupnp-1.6.patch
+++ /dev/null
@@ -1,350 +0,0 @@
-From cb30875bd4e45736ff4ee1137ff97316295ff7be Mon Sep 17 00:00:00 2001
-From: Pablo Barciela <scow@riseup.net>
-Date: Sat, 24 Nov 2018 01:23:58 +0100
-Subject: [PATCH] Fix build with libupnp 1.6
-
----
- src/UPnPBase.cpp | 138 ++++++++++++++++++++++++++++++++++++++++++++++-
- src/UPnPBase.h   |   6 +++
- 2 files changed, 142 insertions(+), 2 deletions(-)
-
-diff --git a/src/UPnPBase.cpp b/src/UPnPBase.cpp
-index d4063a136..774ebfc32 100644
---- a/src/UPnPBase.cpp
-+++ b/src/UPnPBase.cpp
-@@ -1127,7 +1127,11 @@ bool CUPnPControlPoint::PrivateDeletePortMapping(
- 
- 
- // This function is static
-+#if UPNP_VERSION >= 10800
- int CUPnPControlPoint::Callback(Upnp_EventType_e EventType, const void *Event, void * /*Cookie*/)
-+#else
-+int CUPnPControlPoint::Callback(Upnp_EventType EventType, void *Event, void * /*Cookie*/)
-+#endif
- {
- 	std::ostringstream msg;
- 	std::ostringstream msg2;
-@@ -1149,25 +1153,47 @@ int CUPnPControlPoint::Callback(Upnp_EventType_e EventType, const void *Event, v
- 		msg2<< "UPNP_DISCOVERY_SEARCH_RESULT: ";
- 		// UPnP Discovery
- upnpDiscovery:
-+#if UPNP_VERSION >= 10800
- 		UpnpDiscovery *d_event = (UpnpDiscovery *)Event;
-+#else
-+		struct Upnp_Discovery *d_event = (struct Upnp_Discovery *)Event;
-+#endif
- 		IXML_Document *doc = NULL;
-+#if UPNP_VERSION >= 10800
- 		int errCode = UpnpDiscovery_get_ErrCode(d_event);
- 		if (errCode != UPNP_E_SUCCESS) {
- 			msg << UpnpGetErrorMessage(errCode) << ".";
-+#else
-+		int ret;
-+		if (d_event->ErrCode != UPNP_E_SUCCESS) {
-+			msg << UpnpGetErrorMessage(d_event->ErrCode) << ".";
-+#endif
- 			AddDebugLogLineC(logUPnP, msg);
- 		}
- 		// Get the XML tree device description in doc
-+#if UPNP_VERSION >= 10800
- 		const char *location = UpnpDiscovery_get_Location_cstr(d_event);
- 		int ret = UpnpDownloadXmlDoc(location, &doc);
-+#else
-+		ret = UpnpDownloadXmlDoc(d_event->Location, &doc);
-+#endif
- 		if (ret != UPNP_E_SUCCESS) {
- 			msg << "Error retrieving device description from " <<
-+#if UPNP_VERSION >= 10800
- 				location << ": " <<
-+#else
-+				d_event->Location << ": " <<
-+#endif
- 				UpnpGetErrorMessage(ret) <<
- 				"(" << ret << ").";
- 			AddDebugLogLineC(logUPnP, msg);
- 		} else {
- 			msg2 << "Retrieving device description from " <<
-+#if UPNP_VERSION >= 10800
- 				location << ".";
-+#else
-+				d_event->Location << ".";
-+#endif
- 			AddDebugLogLineN(logUPnP, msg2);
- 		}
- 		if (doc) {
-@@ -1195,9 +1221,14 @@ upnpDiscovery:
- 					AddDebugLogLineC(logUPnP, msg);
- 				}
- 				// Add the root device to our list
-+#if UPNP_VERSION >= 10800
- 				int expires = UpnpDiscovery_get_Expires(d_event);
- 				upnpCP->AddRootDevice(rootDevice, urlBase,
- 					location, expires);
-+#else
-+				upnpCP->AddRootDevice(rootDevice, urlBase,
-+					d_event->Location, d_event->Expires);
-+#endif
- 			}
- 			// Free the XML doc tree
- 			IXML::Document::Free(doc);
-@@ -1218,35 +1249,62 @@ upnpDiscovery:
- 	case UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE: {
- 		//fprintf(stderr, "Callback: UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE\n");
- 		// UPnP Device Removed
-+#if UPNP_VERSION >= 10800
- 		UpnpDiscovery *dab_event = (UpnpDiscovery *)Event;
- 		int errCode = UpnpDiscovery_get_ErrCode(dab_event);
- 		if (errCode != UPNP_E_SUCCESS) {
-+#else
-+		struct Upnp_Discovery *dab_event = (struct Upnp_Discovery *)Event;
-+		if (dab_event->ErrCode != UPNP_E_SUCCESS) {
-+#endif
- 			msg << "error(UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE): " <<
-+#if UPNP_VERSION >= 10800
- 				UpnpGetErrorMessage(errCode) <<
-+#else
-+				UpnpGetErrorMessage(dab_event->ErrCode) <<
-+#endif
- 				".";
- 			AddDebugLogLineC(logUPnP, msg);
- 		}
-+#if UPNP_VERSION >= 10800
- 		std::string devType = UpnpDiscovery_get_DeviceType_cstr(dab_event);
-+#else
-+		std::string devType = dab_event->DeviceType;
-+#endif
- 		// Check for an InternetGatewayDevice and removes it from the list
--		std::transform(devType.begin(), devType.end(),
--			devType.begin(), tolower);
-+
-+		std::transform(devType.begin(), devType.end(), devType.begin(), tolower);
-+
- 		if (stdStringIsEqualCI(devType, UPnP::Device::IGW)) {
-+#if UPNP_VERSION >= 10800
- 			const char *deviceID =
- 				UpnpDiscovery_get_DeviceID_cstr(dab_event);
- 			upnpCP->RemoveRootDevice(deviceID);
-+#else
-+			upnpCP->RemoveRootDevice(dab_event->DeviceId);
-+#endif
- 		}
- 		break;
- 	}
- 	case UPNP_EVENT_RECEIVED: {
- 		//fprintf(stderr, "Callback: UPNP_EVENT_RECEIVED\n");
- 		// Event reveived
-+#if UPNP_VERSION >= 10800
- 		UpnpEvent *e_event = (UpnpEvent *)Event;
- 		int eventKey = UpnpEvent_get_EventKey(e_event);
- 		IXML_Document *changedVariables =
- 			UpnpEvent_get_ChangedVariables(e_event);
- 		const std::string sid = UpnpEvent_get_SID_cstr(e_event);
-+#else
-+		struct Upnp_Event *e_event = (struct Upnp_Event *)Event;
-+		const std::string Sid = e_event->Sid;
-+#endif
- 		// Parses the event
-+#if UPNP_VERSION >= 10800
- 		upnpCP->OnEventReceived(sid, eventKey, changedVariables);
-+#else
-+		upnpCP->OnEventReceived(Sid, e_event->EventKey, e_event->ChangedVariables);
-+#endif
- 		break;
- 	}
- 	case UPNP_EVENT_SUBSCRIBE_COMPLETE:
-@@ -1261,19 +1319,38 @@ upnpDiscovery:
- 		//fprintf(stderr, "Callback: UPNP_EVENT_RENEWAL_COMPLETE\n");
- 		msg << "error(UPNP_EVENT_RENEWAL_COMPLETE): ";
- upnpEventRenewalComplete:
-+#if UPNP_VERSION >= 10800
- 		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
- 		int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
- 		if (errCode != UPNP_E_SUCCESS) {
-+#else
-+		struct Upnp_Event_Subscribe *es_event =
-+			(struct Upnp_Event_Subscribe *)Event;
-+		if (es_event->ErrCode != UPNP_E_SUCCESS) {
-+#endif
- 			msg << "Error in Event Subscribe Callback";
-+#if UPNP_VERSION >= 10800
- 			UPnP::ProcessErrorMessage(msg.str(), errCode, NULL, NULL);
-+#else
-+			UPnP::ProcessErrorMessage(
-+				msg.str(), es_event->ErrCode, NULL, NULL);
-+#endif
- 		} else {
- #if 0
-+#if UPNP_VERSION >= 10800
-+
- 			const UpnpString *publisherUrl =
- 				UpnpEventSubscribe_get_PublisherUrl(es_event);
- 			const char *sid = UpnpEvent_get_SID_cstr(es_event);
- 			int timeOut = UpnpEvent_get_TimeOut(es_event);
- 			TvCtrlPointHandleSubscribeUpdate(
- 				publisherUrl, sid, timeOut);
-+#else
-+			TvCtrlPointHandleSubscribeUpdate(
-+				GET_UPNP_STRING(es_event->PublisherUrl),
-+				es_event->Sid,
-+				es_event->TimeOut );
-+#endif
- #endif
- 		}
- 		break;
-@@ -1288,31 +1365,56 @@ upnpEventRenewalComplete:
- 		msg << "error(UPNP_EVENT_SUBSCRIPTION_EXPIRED): ";
- 		msg2 << "UPNP_EVENT_SUBSCRIPTION_EXPIRED: ";
- upnpEventSubscriptionExpired:
-+#if UPNP_VERSION >= 10800
- 		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
-+#else
-+		struct Upnp_Event_Subscribe *es_event =
-+			(struct Upnp_Event_Subscribe *)Event;
-+#endif
- 		Upnp_SID newSID;
- 		memset(newSID, 0, sizeof(Upnp_SID));
- 		int TimeOut = 1801;
-+#if UPNP_VERSION >= 10800
- 		const char *publisherUrl =
- 			UpnpEventSubscribe_get_PublisherUrl_cstr(es_event);
-+#endif
- 		int ret = UpnpSubscribe(
- 			upnpCP->m_UPnPClientHandle,
-+#if UPNP_VERSION >= 10800
- 			publisherUrl,
-+#else
-+			GET_UPNP_STRING(es_event->PublisherUrl),
-+#endif
- 			&TimeOut,
- 			newSID);
- 		if (ret != UPNP_E_SUCCESS) {
- 			msg << "Error Subscribing to EventURL";
-+#if UPNP_VERSION >= 10800
- 			int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
-+#endif
- 			UPnP::ProcessErrorMessage(
-+#if UPNP_VERSION >= 10800
- 				msg.str(), errCode, NULL, NULL);
-+#else
-+				msg.str(), es_event->ErrCode, NULL, NULL);
-+#endif
- 		} else {
- 			ServiceMap::iterator it =
-+#if UPNP_VERSION >= 10800
- 				upnpCP->m_ServiceMap.find(publisherUrl);
-+#else
-+				upnpCP->m_ServiceMap.find(GET_UPNP_STRING(es_event->PublisherUrl));
-+#endif
- 			if (it != upnpCP->m_ServiceMap.end()) {
- 				CUPnPService &service = *(it->second);
- 				service.SetTimeout(TimeOut);
- 				service.SetSID(newSID);
- 				msg2 << "Re-subscribed to EventURL '" <<
-+#if UPNP_VERSION >= 10800
- 					publisherUrl <<
-+#else
-+					GET_UPNP_STRING(es_event->PublisherUrl) <<
-+#endif
- 					"' with SID == '" <<
- 					newSID << "'.";
- 				AddDebugLogLineC(logUPnP, msg2);
-@@ -1331,19 +1433,34 @@ upnpEventSubscriptionExpired:
- 	case UPNP_CONTROL_ACTION_COMPLETE: {
- 		//fprintf(stderr, "Callback: UPNP_CONTROL_ACTION_COMPLETE\n");
- 		// This is here if we choose to do this asynchronously
-+#if UPNP_VERSION >= 10800
- 		UpnpActionComplete *a_event = (UpnpActionComplete *)Event;
- 		int errCode = UpnpActionComplete_get_ErrCode(a_event);
- 		IXML_Document *actionResult =
- 			UpnpActionComplete_get_ActionResult(a_event);
- 		if (errCode != UPNP_E_SUCCESS) {
-+#else
-+		struct Upnp_Action_Complete *a_event =
-+			(struct Upnp_Action_Complete *)Event;
-+		if (a_event->ErrCode != UPNP_E_SUCCESS) {
-+#endif
- 			UPnP::ProcessErrorMessage(
- 				"UpnpSendActionAsync",
-+#if UPNP_VERSION >= 10800
- 				errCode, NULL,
- 				actionResult);
-+#else
-+				a_event->ErrCode, NULL,
-+				a_event->ActionResult);
-+#endif
- 		} else {
- 			// Check the response document
- 			UPnP::ProcessActionResponse(
-+#if UPNP_VERSION >= 10800
- 				actionResult,
-+#else
-+				a_event->ActionResult,
-+#endif
- 				"<UpnpSendActionAsync>");
- 		}
- 		/* No need for any processing here, just print out results.
-@@ -1354,17 +1471,28 @@ upnpEventSubscriptionExpired:
- 	case UPNP_CONTROL_GET_VAR_COMPLETE: {
- 		//fprintf(stderr, "Callback: UPNP_CONTROL_GET_VAR_COMPLETE\n");
- 		msg << "error(UPNP_CONTROL_GET_VAR_COMPLETE): ";
-+#if UPNP_VERSION >= 10800
- 		UpnpStateVarComplete *sv_event = (UpnpStateVarComplete *)Event;
- 		int errCode = UpnpStateVarComplete_get_ErrCode(sv_event);
- 		if (errCode != UPNP_E_SUCCESS) {
-+#else
-+		struct Upnp_State_Var_Complete *sv_event =
-+			(struct Upnp_State_Var_Complete *)Event;
-+		if (sv_event->ErrCode != UPNP_E_SUCCESS) {
-+#endif
- 			msg << "m_UpnpGetServiceVarStatusAsync";
- 			UPnP::ProcessErrorMessage(
-+#if UPNP_VERSION >= 10800
- 				msg.str(), errCode, NULL, NULL);
-+#else
-+				msg.str(), sv_event->ErrCode, NULL, NULL);
-+#endif
- 		} else {
- #if 0
- 			// Warning: The use of UpnpGetServiceVarStatus and
- 			// UpnpGetServiceVarStatusAsync is deprecated by the
- 			// UPnP forum.
-+#if UPNP_VERSION >= 10800
- 			const char *ctrlUrl =
- 				UpnpStateVarComplete_get_CtrlUrl(sv_event);
- 			const char *stateVarName =
-@@ -1373,6 +1501,12 @@ upnpEventSubscriptionExpired:
- 				UpnpStateVarComplete_get_CurrentVal(sv_event);
- 			TvCtrlPointHandleGetVar(
- 				ctrlUrl, stateVarName, currentVal);
-+#else
-+			TvCtrlPointHandleGetVar(
-+				sv_event->CtrlUrl,
-+				sv_event->StateVarName,
-+				sv_event->CurrentVal );
-+#endif
- #endif
- 		}
- 		break;
-diff --git a/src/UPnPBase.h b/src/UPnPBase.h
-index 92753b86a..efe63bf0f 100644
---- a/src/UPnPBase.h
-+++ b/src/UPnPBase.h
-@@ -489,9 +489,15 @@ public:
- 
- 	// Callback function
- 	static int Callback(
-+#if UPNP_VERSION >= 10800
- 		Upnp_EventType_e EventType,
- 		const void *Event,
- 		void *Cookie);
-+#else
-+		Upnp_EventType EventType,
-+		void* Event,
-+		void* Cookie);
-+#endif
- 
- private:
- 	void OnEventReceived(
--- 
-2.24.1
-

diff --git a/net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch b/net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch
deleted file mode 100644
index 42672a85a6a..00000000000
--- a/net-p2p/amule/files/amule-2.3.2-libupnp-1.8.patch
+++ /dev/null
@@ -1,263 +0,0 @@
-From f6dccde218fed8dabd3c61efce02d29b320858fe Mon Sep 17 00:00:00 2001
-From: Marcelo Roberto Jimenez <marcelo.jimenez@gmail.com>
-Date: Tue, 2 Oct 2018 18:17:43 -0300
-Subject: [PATCH] Make aMule compatible with libupnp 1.8
-
----
- src/UPnPBase.cpp | 110 +++++++++++++++++++++++++++--------------------
- src/UPnPBase.h   |   6 +--
- 2 files changed, 66 insertions(+), 50 deletions(-)
-
-diff --git a/src/UPnPBase.cpp b/src/UPnPBase.cpp
-index 01a7c3a05..d4063a136 100644
---- a/src/UPnPBase.cpp
-+++ b/src/UPnPBase.cpp
-@@ -1127,7 +1127,7 @@ bool CUPnPControlPoint::PrivateDeletePortMapping(
- 
- 
- // This function is static
--int CUPnPControlPoint::Callback(Upnp_EventType EventType, void *Event, void * /*Cookie*/)
-+int CUPnPControlPoint::Callback(Upnp_EventType_e EventType, const void *Event, void * /*Cookie*/)
- {
- 	std::ostringstream msg;
- 	std::ostringstream msg2;
-@@ -1149,24 +1149,25 @@ int CUPnPControlPoint::Callback(Upnp_EventType EventType, void *Event, void * /*
- 		msg2<< "UPNP_DISCOVERY_SEARCH_RESULT: ";
- 		// UPnP Discovery
- upnpDiscovery:
--		struct Upnp_Discovery *d_event = (struct Upnp_Discovery *)Event;
-+		UpnpDiscovery *d_event = (UpnpDiscovery *)Event;
- 		IXML_Document *doc = NULL;
--		int ret;
--		if (d_event->ErrCode != UPNP_E_SUCCESS) {
--			msg << UpnpGetErrorMessage(d_event->ErrCode) << ".";
-+		int errCode = UpnpDiscovery_get_ErrCode(d_event);
-+		if (errCode != UPNP_E_SUCCESS) {
-+			msg << UpnpGetErrorMessage(errCode) << ".";
- 			AddDebugLogLineC(logUPnP, msg);
- 		}
- 		// Get the XML tree device description in doc
--		ret = UpnpDownloadXmlDoc(d_event->Location, &doc);
-+		const char *location = UpnpDiscovery_get_Location_cstr(d_event);
-+		int ret = UpnpDownloadXmlDoc(location, &doc);
- 		if (ret != UPNP_E_SUCCESS) {
- 			msg << "Error retrieving device description from " <<
--				d_event->Location << ": " <<
-+				location << ": " <<
- 				UpnpGetErrorMessage(ret) <<
- 				"(" << ret << ").";
- 			AddDebugLogLineC(logUPnP, msg);
- 		} else {
- 			msg2 << "Retrieving device description from " <<
--				d_event->Location << ".";
-+				location << ".";
- 			AddDebugLogLineN(logUPnP, msg2);
- 		}
- 		if (doc) {
-@@ -1194,8 +1195,9 @@ upnpDiscovery:
- 					AddDebugLogLineC(logUPnP, msg);
- 				}
- 				// Add the root device to our list
-+				int expires = UpnpDiscovery_get_Expires(d_event);
- 				upnpCP->AddRootDevice(rootDevice, urlBase,
--					d_event->Location, d_event->Expires);
-+					location, expires);
- 			}
- 			// Free the XML doc tree
- 			IXML::Document::Free(doc);
-@@ -1216,28 +1218,35 @@ upnpDiscovery:
- 	case UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE: {
- 		//fprintf(stderr, "Callback: UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE\n");
- 		// UPnP Device Removed
--		struct Upnp_Discovery *dab_event = (struct Upnp_Discovery *)Event;
--		if (dab_event->ErrCode != UPNP_E_SUCCESS) {
-+		UpnpDiscovery *dab_event = (UpnpDiscovery *)Event;
-+		int errCode = UpnpDiscovery_get_ErrCode(dab_event);
-+		if (errCode != UPNP_E_SUCCESS) {
- 			msg << "error(UPNP_DISCOVERY_ADVERTISEMENT_BYEBYE): " <<
--				UpnpGetErrorMessage(dab_event->ErrCode) <<
-+				UpnpGetErrorMessage(errCode) <<
- 				".";
- 			AddDebugLogLineC(logUPnP, msg);
- 		}
--		std::string devType = dab_event->DeviceType;
-+		std::string devType = UpnpDiscovery_get_DeviceType_cstr(dab_event);
- 		// Check for an InternetGatewayDevice and removes it from the list
--		std::transform(devType.begin(), devType.end(), devType.begin(), tolower);
-+		std::transform(devType.begin(), devType.end(),
-+			devType.begin(), tolower);
- 		if (stdStringIsEqualCI(devType, UPnP::Device::IGW)) {
--			upnpCP->RemoveRootDevice(dab_event->DeviceId);
-+			const char *deviceID =
-+				UpnpDiscovery_get_DeviceID_cstr(dab_event);
-+			upnpCP->RemoveRootDevice(deviceID);
- 		}
- 		break;
- 	}
- 	case UPNP_EVENT_RECEIVED: {
- 		//fprintf(stderr, "Callback: UPNP_EVENT_RECEIVED\n");
- 		// Event reveived
--		struct Upnp_Event *e_event = (struct Upnp_Event *)Event;
--		const std::string Sid = e_event->Sid;
-+		UpnpEvent *e_event = (UpnpEvent *)Event;
-+		int eventKey = UpnpEvent_get_EventKey(e_event);
-+		IXML_Document *changedVariables =
-+			UpnpEvent_get_ChangedVariables(e_event);
-+		const std::string sid = UpnpEvent_get_SID_cstr(e_event);
- 		// Parses the event
--		upnpCP->OnEventReceived(Sid, e_event->EventKey, e_event->ChangedVariables);
-+		upnpCP->OnEventReceived(sid, eventKey, changedVariables);
- 		break;
- 	}
- 	case UPNP_EVENT_SUBSCRIBE_COMPLETE:
-@@ -1252,24 +1261,23 @@ upnpDiscovery:
- 		//fprintf(stderr, "Callback: UPNP_EVENT_RENEWAL_COMPLETE\n");
- 		msg << "error(UPNP_EVENT_RENEWAL_COMPLETE): ";
- upnpEventRenewalComplete:
--		struct Upnp_Event_Subscribe *es_event =
--			(struct Upnp_Event_Subscribe *)Event;
--		if (es_event->ErrCode != UPNP_E_SUCCESS) {
-+		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
-+		int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
-+		if (errCode != UPNP_E_SUCCESS) {
- 			msg << "Error in Event Subscribe Callback";
--			UPnP::ProcessErrorMessage(
--				msg.str(), es_event->ErrCode, NULL, NULL);
-+			UPnP::ProcessErrorMessage(msg.str(), errCode, NULL, NULL);
- 		} else {
- #if 0
-+			const UpnpString *publisherUrl =
-+				UpnpEventSubscribe_get_PublisherUrl(es_event);
-+			const char *sid = UpnpEvent_get_SID_cstr(es_event);
-+			int timeOut = UpnpEvent_get_TimeOut(es_event);
- 			TvCtrlPointHandleSubscribeUpdate(
--				GET_UPNP_STRING(es_event->PublisherUrl),
--				es_event->Sid,
--				es_event->TimeOut );
-+				publisherUrl, sid, timeOut);
- #endif
- 		}
--
- 		break;
- 	}
--
- 	case UPNP_EVENT_AUTORENEWAL_FAILED:
- 		//fprintf(stderr, "Callback: UPNP_EVENT_AUTORENEWAL_FAILED\n");
- 		msg << "error(UPNP_EVENT_AUTORENEWAL_FAILED): ";
-@@ -1280,29 +1288,31 @@ upnpEventRenewalComplete:
- 		msg << "error(UPNP_EVENT_SUBSCRIPTION_EXPIRED): ";
- 		msg2 << "UPNP_EVENT_SUBSCRIPTION_EXPIRED: ";
- upnpEventSubscriptionExpired:
--		struct Upnp_Event_Subscribe *es_event =
--			(struct Upnp_Event_Subscribe *)Event;
-+		UpnpEventSubscribe *es_event = (UpnpEventSubscribe *)Event;
- 		Upnp_SID newSID;
- 		memset(newSID, 0, sizeof(Upnp_SID));
- 		int TimeOut = 1801;
-+		const char *publisherUrl =
-+			UpnpEventSubscribe_get_PublisherUrl_cstr(es_event);
- 		int ret = UpnpSubscribe(
- 			upnpCP->m_UPnPClientHandle,
--			GET_UPNP_STRING(es_event->PublisherUrl),
-+			publisherUrl,
- 			&TimeOut,
- 			newSID);
- 		if (ret != UPNP_E_SUCCESS) {
- 			msg << "Error Subscribing to EventURL";
-+			int errCode = UpnpEventSubscribe_get_ErrCode(es_event);
- 			UPnP::ProcessErrorMessage(
--				msg.str(), es_event->ErrCode, NULL, NULL);
-+				msg.str(), errCode, NULL, NULL);
- 		} else {
- 			ServiceMap::iterator it =
--				upnpCP->m_ServiceMap.find(GET_UPNP_STRING(es_event->PublisherUrl));
-+				upnpCP->m_ServiceMap.find(publisherUrl);
- 			if (it != upnpCP->m_ServiceMap.end()) {
- 				CUPnPService &service = *(it->second);
- 				service.SetTimeout(TimeOut);
- 				service.SetSID(newSID);
- 				msg2 << "Re-subscribed to EventURL '" <<
--					GET_UPNP_STRING(es_event->PublisherUrl) <<
-+					publisherUrl <<
- 					"' with SID == '" <<
- 					newSID << "'.";
- 				AddDebugLogLineC(logUPnP, msg2);
-@@ -1321,17 +1331,19 @@ upnpEventSubscriptionExpired:
- 	case UPNP_CONTROL_ACTION_COMPLETE: {
- 		//fprintf(stderr, "Callback: UPNP_CONTROL_ACTION_COMPLETE\n");
- 		// This is here if we choose to do this asynchronously
--		struct Upnp_Action_Complete *a_event =
--			(struct Upnp_Action_Complete *)Event;
--		if (a_event->ErrCode != UPNP_E_SUCCESS) {
-+		UpnpActionComplete *a_event = (UpnpActionComplete *)Event;
-+		int errCode = UpnpActionComplete_get_ErrCode(a_event);
-+		IXML_Document *actionResult =
-+			UpnpActionComplete_get_ActionResult(a_event);
-+		if (errCode != UPNP_E_SUCCESS) {
- 			UPnP::ProcessErrorMessage(
- 				"UpnpSendActionAsync",
--				a_event->ErrCode, NULL,
--				a_event->ActionResult);
-+				errCode, NULL,
-+				actionResult);
- 		} else {
- 			// Check the response document
- 			UPnP::ProcessActionResponse(
--				a_event->ActionResult,
-+				actionResult,
- 				"<UpnpSendActionAsync>");
- 		}
- 		/* No need for any processing here, just print out results.
-@@ -1342,21 +1354,25 @@ upnpEventSubscriptionExpired:
- 	case UPNP_CONTROL_GET_VAR_COMPLETE: {
- 		//fprintf(stderr, "Callback: UPNP_CONTROL_GET_VAR_COMPLETE\n");
- 		msg << "error(UPNP_CONTROL_GET_VAR_COMPLETE): ";
--		struct Upnp_State_Var_Complete *sv_event =
--			(struct Upnp_State_Var_Complete *)Event;
--		if (sv_event->ErrCode != UPNP_E_SUCCESS) {
-+		UpnpStateVarComplete *sv_event = (UpnpStateVarComplete *)Event;
-+		int errCode = UpnpStateVarComplete_get_ErrCode(sv_event);
-+		if (errCode != UPNP_E_SUCCESS) {
- 			msg << "m_UpnpGetServiceVarStatusAsync";
- 			UPnP::ProcessErrorMessage(
--				msg.str(), sv_event->ErrCode, NULL, NULL);
-+				msg.str(), errCode, NULL, NULL);
- 		} else {
- #if 0
- 			// Warning: The use of UpnpGetServiceVarStatus and
- 			// UpnpGetServiceVarStatusAsync is deprecated by the
- 			// UPnP forum.
-+			const char *ctrlUrl =
-+				UpnpStateVarComplete_get_CtrlUrl(sv_event);
-+			const char *stateVarName =
-+				UpnpStateVarComplete_get_StateVarName(sv_event);
-+			const DOMString currentVal =
-+				UpnpStateVarComplete_get_CurrentVal(sv_event);
- 			TvCtrlPointHandleGetVar(
--				sv_event->CtrlUrl,
--				sv_event->StateVarName,
--				sv_event->CurrentVal );
-+				ctrlUrl, stateVarName, currentVal);
- #endif
- 		}
- 		break;
-diff --git a/src/UPnPBase.h b/src/UPnPBase.h
-index 9eafbd143..92753b86a 100644
---- a/src/UPnPBase.h
-+++ b/src/UPnPBase.h
-@@ -489,9 +489,9 @@ public:
- 
- 	// Callback function
- 	static int Callback(
--		Upnp_EventType EventType,
--		void* Event,
--		void* Cookie);
-+		Upnp_EventType_e EventType,
-+		const void *Event,
-+		void *Cookie);
- 
- private:
- 	void OnEventReceived(
--- 
-2.24.1
-


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/
@ 2023-12-19  5:23 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2023-12-19  5:23 UTC (permalink / raw
  To: gentoo-commits

commit:     8a20cd57141719ddaba351259d807ed827653c9c
Author:     Matoro Mahri <matoro_gentoo <AT> matoro <DOT> tk>
AuthorDate: Sat Dec 16 04:28:22 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Dec 19 05:20:05 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8a20cd57

net-p2p/amule: wire up tests

See: https://github.com/amule-project/amule/issues/342
See: https://github.com/amule-project/amule/pull/368
Bug: https://bugs.gentoo.org/841296
Signed-off-by: Matoro Mahri <matoro_gentoo <AT> matoro.tk>
Closes: https://github.com/gentoo/gentoo/pull/34307
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../{amule-9999.ebuild => amule-2.3.3-r2.ebuild}   | 13 ++++--
 net-p2p/amule/amule-9999.ebuild                    |  6 +++
 .../amule/files/amule-2.3.3-backport-pr368.patch   | 52 ++++++++++++++++++++++
 3 files changed, 68 insertions(+), 3 deletions(-)

diff --git a/net-p2p/amule/amule-9999.ebuild b/net-p2p/amule/amule-2.3.3-r2.ebuild
similarity index 91%
copy from net-p2p/amule/amule-9999.ebuild
copy to net-p2p/amule/amule-2.3.3-r2.ebuild
index 1dc6203a5561..f4b6d406428c 100644
--- a/net-p2p/amule/amule-9999.ebuild
+++ b/net-p2p/amule/amule-2.3.3-r2.ebuild
@@ -4,16 +4,16 @@
 EAPI=8
 WX_GTK_VER="3.0-gtk3"
 
-inherit flag-o-matic wxwidgets xdg-utils
+inherit autotools flag-o-matic wxwidgets xdg-utils
 
 if [[ ${PV} == 9999 ]] ; then
 	EGIT_REPO_URI="https://github.com/amule-project/amule"
-	inherit autotools git-r3
+	inherit git-r3
 else
 	MY_P="${PN/m/M}-${PV}"
 	SRC_URI="https://download.sourceforge.net/${PN}/${MY_P}.tar.xz"
 	S="${WORKDIR}/${MY_P}"
-	KEYWORDS="~alpha ~amd64 ~arm ~ppc ~ppc64 ~sparc ~x86"
+	KEYWORDS="~alpha ~amd64 ~arm ~ppc ~ppc64 ~riscv ~sparc ~x86"
 fi
 
 DESCRIPTION="aMule, the all-platform eMule p2p client"
@@ -52,6 +52,8 @@ BDEPEND="
 PATCHES=(
 	"${FILESDIR}/${PN}-2.3.2-disable-version-check.patch"
 	"${FILESDIR}/${PN}-2.3.3-fix-exception.patch"
+	"${FILESDIR}/${P}-autoconf-2.70.patch"
+	"${FILESDIR}/${PN}-2.3.3-backport-pr368.patch"
 )
 
 pkg_setup() {
@@ -70,6 +72,7 @@ src_prepare() {
 }
 
 src_configure() {
+	use debug || append-cppflags -DwxDEBUG_LEVEL=0
 	append-cxxflags -std=gnu++14
 
 	local myconf=(
@@ -105,6 +108,10 @@ src_configure() {
 	econf "${myconf[@]}"
 }
 
+src_test() {
+	emake check
+}
+
 src_install() {
 	default
 

diff --git a/net-p2p/amule/amule-9999.ebuild b/net-p2p/amule/amule-9999.ebuild
index 1dc6203a5561..c1743eff2384 100644
--- a/net-p2p/amule/amule-9999.ebuild
+++ b/net-p2p/amule/amule-9999.ebuild
@@ -52,6 +52,7 @@ BDEPEND="
 PATCHES=(
 	"${FILESDIR}/${PN}-2.3.2-disable-version-check.patch"
 	"${FILESDIR}/${PN}-2.3.3-fix-exception.patch"
+	"${FILESDIR}/${PN}-2.3.3-backport-pr368.patch"
 )
 
 pkg_setup() {
@@ -70,6 +71,7 @@ src_prepare() {
 }
 
 src_configure() {
+	use debug || append-cppflags -DwxDEBUG_LEVEL=0
 	append-cxxflags -std=gnu++14
 
 	local myconf=(
@@ -105,6 +107,10 @@ src_configure() {
 	econf "${myconf[@]}"
 }
 
+src_test() {
+	emake check
+}
+
 src_install() {
 	default
 

diff --git a/net-p2p/amule/files/amule-2.3.3-backport-pr368.patch b/net-p2p/amule/files/amule-2.3.3-backport-pr368.patch
new file mode 100644
index 000000000000..9235276943b8
--- /dev/null
+++ b/net-p2p/amule/files/amule-2.3.3-backport-pr368.patch
@@ -0,0 +1,52 @@
+https://bugs.gentoo.org/841296
+https://github.com/amule-project/amule/issues/342
+https://github.com/amule-project/amule/pull/368
+
+commit 1c57ce9c688d26d95fe8f9d7b7590f4670956749
+Author: matoro <matoro@users.noreply.github.com>
+Date:   Thu Dec 14 00:28:50 2023 -0500
+
+    SafeFile: do endian-swap on float tag values
+    
+    There are comments noting that writing raw float values may not be
+    endian-correct and indeed it is not.  WX does not provide functions for
+    endian-swapping floats, but since amule explicitly uses exclusively
+    single-precision (32-bit) floats, just cast it into a uint32_t for the
+    swapping.
+    
+    This is a no-op on little-endian.
+
+diff --git a/src/SafeFile.cpp b/src/SafeFile.cpp
+index 30f9a7f23..0d9c4f8e7 100644
+--- a/src/SafeFile.cpp
++++ b/src/SafeFile.cpp
+@@ -31,6 +31,7 @@
+ #include <common/Format.h>		// Needed for CFormat
+ #include "CompilerSpecific.h"		// Needed for __FUNCTION__
+ 
++#include <cstring>              // For std::memcpy
+ 
+ #define CHECK_BOM(size, x) ((size >= 3)  && (x[0] == (char)0xEF) && (x[1] == (char)0xBB) && (x[2] == (char)0xBF))
+ 
+@@ -189,6 +190,10 @@ float CFileDataIO::ReadFloat() const
+ {
+ 	float retVal;
+ 	Read(&retVal, sizeof(float));
++	uint32_t toswap{};
++	std::memcpy(&toswap, &retVal, sizeof(toswap));
++	toswap = ENDIAN_SWAP_32(toswap);
++	std::memcpy(&retVal, &toswap, sizeof(retVal));
+ 	return retVal;
+ }
+ 
+@@ -306,6 +311,10 @@ void CFileDataIO::WriteHash(const CMD4Hash& value)
+ 
+ void CFileDataIO::WriteFloat(float value)
+ {
++	uint32_t toswap{};
++	std::memcpy(&toswap, &value, sizeof(toswap));
++	toswap = ENDIAN_SWAP_32(toswap);
++	std::memcpy(&value, &toswap, sizeof(value));
+ 	Write(&value, sizeof(float));
+ }
+ 


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-12-19  5:23 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-02-20 13:27 [gentoo-commits] repo/gentoo:master commit in: net-p2p/amule/files/, net-p2p/amule/ Joonas Niilola
  -- strict thread matches above, loose matches on Subject: below --
2023-12-19  5:23 Sam James
2021-06-21 22:26 Sam James
2020-09-03 11:40 Hanno Böck
2020-06-20 20:31 Thomas Deutschmann
2020-01-17  6:23 Joonas Niilola
2019-04-22  7:26 Michał Górny
2019-04-22  7:26 Michał Górny
2017-06-24  2:17 Michael Palimaka
2016-05-03 17:35 Austin English

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox