commit:     f0c051ae8fa760db1ed92bc9bdcaf30d7a53481e
Author:     Alfred Persson <cat <AT> catcream <DOT> org>
AuthorDate: Thu Apr  7 01:46:53 2022 +0000
Commit:     Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Thu Apr  7 01:52:19 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f0c051ae

dev-util/flatpak-builder: add musl patch

Closes: https://bugs.gentoo.org/834671
Signed-off-by: Zac Medico <zmedico <AT> gentoo.org>

 .../files/flatpak-builder-1.2.2-musl.patch             | 18 ++++++++++++++++++
 dev-util/flatpak-builder/flatpak-builder-1.2.2.ebuild  |  2 ++
 2 files changed, 20 insertions(+)

diff --git a/dev-util/flatpak-builder/files/flatpak-builder-1.2.2-musl.patch 
b/dev-util/flatpak-builder/files/flatpak-builder-1.2.2-musl.patch
new file mode 100644
index 000000000000..db207e0e353c
--- /dev/null
+++ b/dev-util/flatpak-builder/files/flatpak-builder-1.2.2-musl.patch
@@ -0,0 +1,18 @@
+--- a/subprojects/libglnx/glnx-macros.h
++++ b/subprojects/libglnx/glnx-macros.h
+@@ -28,6 +28,16 @@
+
+ G_BEGIN_DECLS
+
++/* taken from glibc unistd.h and fixes musl */
++#ifndef TEMP_FAILURE_RETRY
++#define TEMP_FAILURE_RETRY(expression) \
++  (__extension__                                                              
\
++    ({ long int __result;                                                     
\
++       do __result = (long int) (expression);                                 
\
++       while (__result == -1L && errno == EINTR);                             
\
++       __result; }))
++#endif
++
+ /* All of these are for C only. */
+ #ifndef __GI_SCANNER__

diff --git a/dev-util/flatpak-builder/flatpak-builder-1.2.2.ebuild 
b/dev-util/flatpak-builder/flatpak-builder-1.2.2.ebuild
index 990f3dd875d5..f135df85fc71 100644
--- a/dev-util/flatpak-builder/flatpak-builder-1.2.2.ebuild
+++ b/dev-util/flatpak-builder/flatpak-builder-1.2.2.ebuild
@@ -33,6 +33,8 @@ BDEPEND="
        )
 "
 
+PATCHES=("${FILESDIR}/flatpak-builder-1.2.2-musl.patch")
+
 src_configure() {
        econf \
                $(use_enable doc documentation) \

Reply via email to