summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-crypt/gpgme/files')
-rw-r--r--app-crypt/gpgme/files/ecd0c86d62351d267bdc9566286c532a394c711b.patch40
-rw-r--r--app-crypt/gpgme/files/gpgme-1.18.0-tests-start-stop-agent-use-command-v.patch27
-rw-r--r--app-crypt/gpgme/files/gpgme-1.23.1-tests-gnupg-no-tofu.patch26
3 files changed, 93 insertions, 0 deletions
diff --git a/app-crypt/gpgme/files/ecd0c86d62351d267bdc9566286c532a394c711b.patch b/app-crypt/gpgme/files/ecd0c86d62351d267bdc9566286c532a394c711b.patch
new file mode 100644
index 000000000000..5e7a37d9ff01
--- /dev/null
+++ b/app-crypt/gpgme/files/ecd0c86d62351d267bdc9566286c532a394c711b.patch
@@ -0,0 +1,40 @@
+From ecd0c86d62351d267bdc9566286c532a394c711b Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Ingo=20Kl=C3=B6cker?= <dev@ingo-kloecker.de>
+Date: Mon, 2 Sep 2024 15:33:25 +0200
+Subject: [PATCH] build,python: Fix build with setuptools 72.2.0+
+
+* lang/python/setup.py.in (BuildExtFirstHack.run): Extend members of the
+extension instead of lists that were passed to the extension.
+--
+
+setuptools 72.2.0 integrated changes in distutils which included
+"Support for Pathlike objects in data files and extensions". With this
+change the extensions now take a copy of the sources list passed to the
+constructor instead of keeping a reference to the passed list. Hence,
+modifying the sources list that was passed to the extension didn't
+change the sources list of the extension anymore. This is fixed by
+modifying the sources list of the extension directly. For consistency
+we do the same for the swig_opts list.
+
+GnuPG-bug-id: 7281
+---
+ lang/python/setup.py.in | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/lang/python/setup.py.in b/lang/python/setup.py.in
+index 7b64ba7b..d6f537e0 100755
+--- a/lang/python/setup.py.in
++++ b/lang/python/setup.py.in
+@@ -217,9 +217,9 @@ class BuildExtFirstHack(build):
+ def run(self):
+ self._generate()
+
+- swig_sources.extend((self._in_build_base('gpgme.i'),
+- self._in_build_base('helpers.c')))
+- swig_opts.extend([
++ swige.sources.extend((self._in_build_base('gpgme.i'),
++ self._in_build_base('helpers.c')))
++ swige.swig_opts.extend([
+ '-I' + self.build_base, '-outdir',
+ os.path.join(self.build_lib, 'gpg')
+ ])
diff --git a/app-crypt/gpgme/files/gpgme-1.18.0-tests-start-stop-agent-use-command-v.patch b/app-crypt/gpgme/files/gpgme-1.18.0-tests-start-stop-agent-use-command-v.patch
new file mode 100644
index 000000000000..aeae35f45636
--- /dev/null
+++ b/app-crypt/gpgme/files/gpgme-1.18.0-tests-start-stop-agent-use-command-v.patch
@@ -0,0 +1,27 @@
+Sent upstream to gnupg-devel@ but not yet in archive.
+
+From: Sam James <sam@gentoo.org>
+Date: Mon, 15 Aug 2022 19:29:06 +0100
+Subject: [PATCH] tests/start-stop-agent: use 'command -v' instead of 'which'
+
+`which` is an external command which isn't required by POSIX.
+
+Debian and other distributions (like Gentoo!) are looking
+to drop it from their base set of packages.
+
+Switch to `command -v` which should always work instead.
+
+Note we already use `command -v` at the start of this test anyway.
+
+Signed-off-by: Sam James <sam@gentoo.org>
+--- a/tests/start-stop-agent
++++ b/tests/start-stop-agent
+@@ -15,7 +15,7 @@ fi
+
+ GPG_AGENT_INFO=
+ export GPG_AGENT_INFO
+-GPG_AGENT=$(which gpg-agent)
++GPG_AGENT=$(command -v gpg-agent)
+
+ token=$(echo "gpgme-$(pwd)" | tr ' ' '_')
+
diff --git a/app-crypt/gpgme/files/gpgme-1.23.1-tests-gnupg-no-tofu.patch b/app-crypt/gpgme/files/gpgme-1.23.1-tests-gnupg-no-tofu.patch
new file mode 100644
index 000000000000..831f68c8ea18
--- /dev/null
+++ b/app-crypt/gpgme/files/gpgme-1.23.1-tests-gnupg-no-tofu.patch
@@ -0,0 +1,26 @@
+https://dev.gnupg.org/T6778
+--- a/lang/python/tests/support.py
++++ b/lang/python/tests/support.py
+@@ -46,13 +46,15 @@ def is_gpg_version(version):
+
+
+ def have_tofu_support(ctx, some_uid):
+- keys = list(
+- ctx.keylist(
+- some_uid,
+- mode=(gpg.constants.keylist.mode.LOCAL |
+- gpg.constants.keylist.mode.WITH_TOFU)))
+- return len(keys) > 0
+-
++ try:
++ keys = list(
++ ctx.keylist(
++ some_uid,
++ mode=(gpg.constants.keylist.mode.LOCAL |
++ gpg.constants.keylist.mode.WITH_TOFU)))
++ return len(keys) > 0
++ except gpg.errors.GPGMEError:
++ return False
+
+ # Skip the Python tests for GnuPG < 2.1.12. Prior versions do not
+ # understand the command line flags that we assume exist. C.f. issue