summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2024-03-17 03:10:06 +0000
committerSam James <sam@gentoo.org>2024-03-17 03:10:06 +0000
commitda33ef820a414ac3f3aba54fd9099cc4494d13fe (patch)
tree3b4e89c672170cc883b037d8503691fa7e124e4f /gnome-base/gnome-keyring
parentlxde-base/lxpanel: add github upstream metadata (diff)
downloadgentoo-da33ef820a414ac3f3aba54fd9099cc4494d13fe.tar.gz
gentoo-da33ef820a414ac3f3aba54fd9099cc4494d13fe.tar.bz2
gentoo-da33ef820a414ac3f3aba54fd9099cc4494d13fe.zip
gnome-base/gnome-keyring: fix modern C issue in tests
Closes: https://bugs.gentoo.org/922630 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'gnome-base/gnome-keyring')
-rw-r--r--gnome-base/gnome-keyring/files/gnome-keyring-42.1-c99.patch40
-rw-r--r--gnome-base/gnome-keyring/gnome-keyring-42.1-r2.ebuild4
2 files changed, 44 insertions, 0 deletions
diff --git a/gnome-base/gnome-keyring/files/gnome-keyring-42.1-c99.patch b/gnome-base/gnome-keyring/files/gnome-keyring-42.1-c99.patch
new file mode 100644
index 000000000000..3dfd578b7407
--- /dev/null
+++ b/gnome-base/gnome-keyring/files/gnome-keyring-42.1-c99.patch
@@ -0,0 +1,40 @@
+https://bugs.gentoo.org/922630
+https://gitlab.gnome.org/GNOME/gnome-keyring/-/commit/f298c87e14e89656992ccfd17b133f4f2ab9c5ea
+
+From f298c87e14e89656992ccfd17b133f4f2ab9c5ea Mon Sep 17 00:00:00 2001
+From: Yaakov Selkowitz <yselkowi@redhat.com>
+Date: Wed, 24 Jan 2024 14:01:06 -0500
+Subject: [PATCH] gkm: fix test-sexp with GCC 14
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+pkcs11/gkm/test-sexp.c: In function ‘test_sign_verify’:
+pkcs11/gkm/test-sexp.c:231:92: error: passing argument 6 of ‘gkm_crypto_sign_xsa’ from incompatible pointer type [-Wincompatible-pointer-types]
+In file included from pkcs11/gkm/test-sexp.c:31:
+./pkcs11/gkm/gkm-crypto.h:92:86: note: expected ‘CK_ULONG_PTR’ {aka ‘long unsigned int *’} but argument is of type ‘gsize *’ {aka ‘unsigned int *’}
+pkcs11/gkm/test-sexp.c:251:87: error: passing argument 6 of ‘gkm_crypto_sign_xsa’ from incompatible pointer type [-Wincompatible-pointer-types]
+./pkcs11/gkm/gkm-crypto.h:92:86: note: expected ‘CK_ULONG_PTR’ {aka ‘long unsigned int *’} but argument is of type ‘gsize *’ {aka ‘unsigned int *’}
+pkcs11/gkm/test-sexp.c:271:91: error: passing argument 6 of ‘gkm_crypto_sign_xsa’ from incompatible pointer type [-Wincompatible-pointer-types]
+./pkcs11/gkm/gkm-crypto.h:92:86: note: expected ‘CK_ULONG_PTR’ {aka ‘long unsigned int *’} but argument is of type ‘gsize *’ {aka ‘unsigned int *’}
+
+Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
+--- a/pkcs11/gkm/test-sexp.c
++++ b/pkcs11/gkm/test-sexp.c
+@@ -221,10 +221,10 @@ test_sign_verify (Test *test, gconstpointer unused)
+ {
+ gcry_sexp_t pubkey = NULL;
+ gboolean ret;
+- guchar data[] = TEST_DATA;
+- guchar data_size = TEST_DATA_SIZE;
+- guchar signature[128];
+- gsize signature_size = 128;
++ CK_BYTE data[] = TEST_DATA;
++ CK_ULONG data_size = TEST_DATA_SIZE;
++ CK_BYTE signature[128];
++ CK_ULONG signature_size = 128;
+
+ /* RSA */
+ /* sign some data */
+--
+GitLab
diff --git a/gnome-base/gnome-keyring/gnome-keyring-42.1-r2.ebuild b/gnome-base/gnome-keyring/gnome-keyring-42.1-r2.ebuild
index 5cce53f7b4df..a2696c83bd79 100644
--- a/gnome-base/gnome-keyring/gnome-keyring-42.1-r2.ebuild
+++ b/gnome-base/gnome-keyring/gnome-keyring-42.1-r2.ebuild
@@ -40,6 +40,10 @@ BDEPEND="
test? ( ${PYTHON_DEPS} )
"
+PATCHES=(
+ "${FILESDIR}"/gnome-keyring-42.1-c99.patch
+)
+
pkg_setup() {
use test && python-any-r1_pkg_setup
}