Signed-off-by: Khem Raj <[email protected]>
---
 ...ix-io.c-Use-off_t-instead-of-off64_t.patch | 42 +++++++++++++++++++
 meta/recipes-support/gpgme/gpgme_1.18.0.bb    |  1 +
 2 files changed, 43 insertions(+)
 create mode 100644 
meta/recipes-support/gpgme/gpgme/0001-posix-io.c-Use-off_t-instead-of-off64_t.patch

diff --git 
a/meta/recipes-support/gpgme/gpgme/0001-posix-io.c-Use-off_t-instead-of-off64_t.patch
 
b/meta/recipes-support/gpgme/gpgme/0001-posix-io.c-Use-off_t-instead-of-off64_t.patch
new file mode 100644
index 0000000000..be58c42128
--- /dev/null
+++ 
b/meta/recipes-support/gpgme/gpgme/0001-posix-io.c-Use-off_t-instead-of-off64_t.patch
@@ -0,0 +1,42 @@
+From be33cf1812b4c2a3ed85fb2532992bfb2b27b3be Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Thu, 15 Dec 2022 08:44:13 -0800
+Subject: [PATCH] posix-io.c: Use off_t instead of off64_t
+
+configure.ac checks for largefile support via AC_SYS_LARGEFILE already,
+therefore use off_t and ino_t instead of 64bit variants. Musl e.g. does
+not define them without _LARGEFILE64_SOURCE and error is not seen on
+glibc because _GNU_SOURCE defines _LARGEFILE64_SOURCE
+
+Fixes errors like below on 32-bit musl systems
+
+../../../../../../../../workspace/sources/gpgme/src/posix-io.c:77:3: error: 
unknown type name 'ino64_t'; did you mean 'int64_t'?
+  ino64_t d_ino;
+  ^~~~~~~
+  int64_t
+                        ^
+../../../../../../../../workspace/sources/gpgme/src/posix-io.c:78:3: error: 
unknown type name 'off64_t'; did you mean 'off_t'?
+  off64_t d_off;
+  ^~~~~~~
+
+Upstream-Status: Submitted 
[https://lists.gnupg.org/pipermail/gnupg-devel/2022-December/035222.html]
+Signed-off-by: Khem Raj <[email protected]>
+---
+ src/posix-io.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/posix-io.c b/src/posix-io.c
+index 0d0a98b..286a626 100644
+--- a/src/posix-io.c
++++ b/src/posix-io.c
+@@ -74,8 +74,8 @@
+  * define it ourselves.  */
+ struct linux_dirent64
+ {
+-  ino64_t d_ino;
+-  off64_t d_off;
++  ino_t d_ino;
++  off_t d_off;
+   unsigned short d_reclen;
+   unsigned char d_type;
+   char d_name[];
diff --git a/meta/recipes-support/gpgme/gpgme_1.18.0.bb 
b/meta/recipes-support/gpgme/gpgme_1.18.0.bb
index 40c41876fa..7ff4837d6f 100644
--- a/meta/recipes-support/gpgme/gpgme_1.18.0.bb
+++ b/meta/recipes-support/gpgme/gpgme_1.18.0.bb
@@ -21,6 +21,7 @@ SRC_URI = "${GNUPG_MIRROR}/gpgme/${BP}.tar.bz2 \
            file://0007-python-Add-variables-to-tests.patch \
            file://0008-do-not-auto-check-var-PYTHON.patch \
            file://0001-use-closefrom-on-linux-and-glibc-2.34.patch \
+           file://0001-posix-io.c-Use-off_t-instead-of-off64_t.patch \
            "
 
 SRC_URI[sha256sum] = 
"361d4eae47ce925dba0ea569af40e7b52c645c4ae2e65e5621bf1b6cdd8b0e9e"
-- 
2.39.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#174927): 
https://lists.openembedded.org/g/openembedded-core/message/174927
Mute This Topic: https://lists.openembedded.org/mt/95811573/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to