From: "James Le Cuirot" <chewi@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: games-strategy/0ad/files/, games-strategy/0ad/
Date: Sun, 16 Jun 2024 22:34:35 +0000 (UTC) [thread overview]
Message-ID: <1718577230.57d4ce1472ddaf7879e4419495c037420155920b.chewi@gentoo> (raw)
commit: 57d4ce1472ddaf7879e4419495c037420155920b
Author: James Le Cuirot <chewi <AT> gentoo <DOT> org>
AuthorDate: Sun Jun 16 22:33:50 2024 +0000
Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org>
CommitDate: Sun Jun 16 22:33:50 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=57d4ce14
games-strategy/0ad: Fix compatibility with miniupnpc 2.2.8 with patch
Thanks to Torsten Kaiser for the patch.
Closes: https://bugs.gentoo.org/934315
Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>
games-strategy/0ad/0ad-0.0.26_alpha-r1.ebuild | 1 +
.../0ad/files/0ad-0.0.26_alpha-miniupnpc.patch | 38 ++++++++++++++++++++++
2 files changed, 39 insertions(+)
diff --git a/games-strategy/0ad/0ad-0.0.26_alpha-r1.ebuild b/games-strategy/0ad/0ad-0.0.26_alpha-r1.ebuild
index 7c7373e81a78..e910f14e5bd2 100644
--- a/games-strategy/0ad/0ad-0.0.26_alpha-r1.ebuild
+++ b/games-strategy/0ad/0ad-0.0.26_alpha-r1.ebuild
@@ -103,6 +103,7 @@ PATCHES=(
"${FILESDIR}"/${P}-libxml2-2.12.patch
# https://code.wildfiregames.com/D5267
"${FILESDIR}"/${P}-boost-1.85.patch
+ "${FILESDIR}"/${P}-miniupnpc.patch
)
pkg_setup() {
diff --git a/games-strategy/0ad/files/0ad-0.0.26_alpha-miniupnpc.patch b/games-strategy/0ad/files/0ad-0.0.26_alpha-miniupnpc.patch
new file mode 100644
index 000000000000..f17cee4e36f2
--- /dev/null
+++ b/games-strategy/0ad/files/0ad-0.0.26_alpha-miniupnpc.patch
@@ -0,0 +1,38 @@
+Adapt to changes from API 18
+
+https://github.com/miniupnp/miniupnp/commit/c0a50ce33e3b99ce8a96fd43049bb5b53ffac62f
+https://bugs.gentoo.org/934315
+
+--- a/source/network/NetServer.cpp 2022-09-23 21:17:14.000000000 +0200
++++ a/source/network/NetServer.cpp 2024-06-14 21:43:26.572418719 +0200
+@@ -302,7 +302,11 @@
+ else if ((devlist = upnpDiscover(10000, 0, 0, 0, 0, 0)) != NULL)
+ #endif
+ {
++#if defined(MINIUPNPC_API_VERSION) && MINIUPNPC_API_VERSION >= 18
++ ret = UPNP_GetValidIGD(devlist, &urls, &data, internalIPAddress, sizeof(internalIPAddress), NULL, 0);
++#else
+ ret = UPNP_GetValidIGD(devlist, &urls, &data, internalIPAddress, sizeof(internalIPAddress));
++#endif
+ allocatedUrls = ret != 0; // urls is allocated on non-zero return values
+ }
+ else
+@@ -321,9 +325,18 @@
+ LOGMESSAGE("Net server: found valid IGD = %s", urls.controlURL);
+ break;
+ case 2:
++#if defined(MINIUPNPC_API_VERSION) && MINIUPNPC_API_VERSION >= 18
++ LOGMESSAGE("Net server: found a valid IGD with a reserved address = %s, will try to continue anyway", urls.controlURL);
++ break;
++ case 3:
++ LOGMESSAGE("Net server: found a valid, not connected IGD = %s, will try to continue anyway", urls.controlURL);
++ break;
++ case 4:
++#else
+ LOGMESSAGE("Net server: found a valid, not connected IGD = %s, will try to continue anyway", urls.controlURL);
+ break;
+ case 3:
++#endif
+ LOGMESSAGE("Net server: found a UPnP device unrecognized as IGD = %s, will try to continue anyway", urls.controlURL);
+ break;
+ default:
next reply other threads:[~2024-06-16 22:34 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-16 22:34 James Le Cuirot [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-03-10 2:21 [gentoo-commits] repo/gentoo:master commit in: games-strategy/0ad/files/, games-strategy/0ad/ Sam James
2024-05-28 1:45 Sam James
2023-08-22 13:12 Andrew Ammerlaan
2022-06-07 0:41 Sam James
2022-02-07 4:31 Sam James
2022-02-07 4:31 Sam James
2021-06-17 23:24 Sam James
2021-01-17 1:17 Sam James
2015-08-14 23:10 Julian Ospald
2015-08-14 23:10 Julian Ospald
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1718577230.57d4ce1472ddaf7879e4419495c037420155920b.chewi@gentoo \
--to=chewi@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox