Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-crypt/gpgme/, app-crypt/gpgme/files/
Date: Mon, 06 Sep 2021 15:59:03
Message-Id: 1630943929.5fac28c428be08a81a1c08ab2967f2afee45bdd6.soap@gentoo
1 commit: 5fac28c428be08a81a1c08ab2967f2afee45bdd6
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Mon Sep 6 15:58:49 2021 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Mon Sep 6 15:58:49 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5fac28c4
7
8 app-crypt/gpgme: [QA] revert e4f93d3d9d0608a84aaa8afcafc410a1b705e71a
9
10 * The revert was done without technical reason, over three weeks
11 after the initial request, and the corresponding bug was not
12 re-opened.
13
14 Bug: https://bugs.gentoo.org/803557
15 Signed-off-by: David Seifert <soap <AT> gentoo.org>
16
17 .../gpgme/files/gpgme-1.16.0-glibc-2.34.patch | 33 ++++++++++++++++++++++
18 app-crypt/gpgme/gpgme-1.16.0.ebuild | 4 +++
19 2 files changed, 37 insertions(+)
20
21 diff --git a/app-crypt/gpgme/files/gpgme-1.16.0-glibc-2.34.patch b/app-crypt/gpgme/files/gpgme-1.16.0-glibc-2.34.patch
22 new file mode 100644
23 index 00000000000..f328e4540ae
24 --- /dev/null
25 +++ b/app-crypt/gpgme/files/gpgme-1.16.0-glibc-2.34.patch
26 @@ -0,0 +1,33 @@
27 +https://bugs.gentoo.org/803557
28 +https://dev.gnupg.org/T5587
29 +
30 +From: Fabrice Fontaine <fontaine.fabrice@×××××.com>
31 +Date: Sun, 5 Sep 2021 00:05:00 +0200
32 +Subject: [PATCH] src/posix-io.c: fix build with glibc >= 2.34
33 +
34 +Fix the following build failure with glibc >= 2.34 raised because
35 +closefrom doesn't return an int but a void since its addition with
36 +https://github.com/bminor/glibc/commit/607449506f197cc9514408908f41f22537a47a8c
37 +
38 +```
39 +posix-io.c: In function '_gpgme_io_spawn':
40 +posix-io.c:577:23: error: void value not ignored as it ought to be
41 + 577 | while ((i = closefrom (fd)) && errno == EINTR)
42 + | ^
43 +```
44 +
45 +Fixes:
46 + - http://autobuild.buildroot.org/results/b11094ddd35263071b7dd453a6590c5b684026ff
47 +
48 +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@×××××.com>
49 +--- a/src/posix-io.c
50 ++++ b/src/posix-io.c
51 +@@ -570,7 +570,7 @@ _gpgme_io_spawn (const char *path, char *const argv[], unsigned int flags,
52 + if (fd_list[i].fd > fd)
53 + fd = fd_list[i].fd;
54 + fd++;
55 +-#if defined(__sun) || defined(__FreeBSD__)
56 ++#if defined(__sun) || defined(__FreeBSD__) || (defined (__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 34)
57 + closefrom (fd);
58 + max_fds = fd;
59 + #else /*!__sun */
60
61 diff --git a/app-crypt/gpgme/gpgme-1.16.0.ebuild b/app-crypt/gpgme/gpgme-1.16.0.ebuild
62 index ed9a1cc7e57..d8df58daf47 100644
63 --- a/app-crypt/gpgme/gpgme-1.16.0.ebuild
64 +++ b/app-crypt/gpgme/gpgme-1.16.0.ebuild
65 @@ -29,6 +29,10 @@ BDEPEND="python? ( dev-lang/swig )"
66
67 REQUIRED_USE="qt5? ( cxx ) python? ( ${PYTHON_REQUIRED_USE} )"
68
69 +PATCHES=(
70 + "${FILESDIR}"/${P}-glibc-2.34.patch
71 +)
72 +
73 do_python() {
74 if use python; then
75 pushd "lang/python" > /dev/null || die