aboutsummaryrefslogtreecommitdiffstats
path: root/testing/ostree/musl-fixes.patch
blob: 4b1098e1ee0b6e2d571c89bddf5f3b8dbca53f62 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
--- a/src/libostree/ostree-repo.c
+++ b/src/libostree/ostree-repo.c
@@ -43,6 +43,8 @@
 #include <locale.h>
 #include <glib/gstdio.h>
 
+#include <sys/file.h>
+
 /**
  * SECTION:ostree-repo
  * @title: Content-addressed object store
--- a/src/libostree/ostree-sysroot.c
+++ b/src/libostree/ostree-sysroot.c
@@ -21,6 +21,7 @@
 #include "config.h"
 
 #include "otutil.h"
+#include <sys/file.h>
 #include <sys/mount.h>
 #include <sys/wait.h>
 
--- a/config.h.in
+++ b/config.h.in
@@ -148,3 +148,15 @@
 
 /* Define to 1 if you need to in order for `stat' and other things to work. */
 #undef _POSIX_SOURCE
+
+/* 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
+
+