mirror of
https://github.com/valitydev/gentoo-overlay.git
synced 2024-11-06 09:55:21 +00:00
app-emulation/cri-o: add Fix-pinns-compilation-for-TEMP_FAILURE_RETRY.patch
This commit is contained in:
parent
63572f1b3c
commit
a196d34c37
@ -38,6 +38,10 @@ DEPEND="
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<app-emulation/libpod-1.3.2-r1"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/0001-Fix-pinns-compilation-for-TEMP_FAILURE_RETRY.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
|
||||
|
@ -0,0 +1,39 @@
|
||||
From c59fd827138efb66226811fb312be41ef1a15e3c Mon Sep 17 00:00:00 2001
|
||||
From: Alexander Miroshnichenko <alex@millerson.name>
|
||||
Date: Tue, 26 Jan 2021 12:34:11 +0300
|
||||
Subject: [PATCH] Fix pinns compilation for TEMP_FAILURE_RETRY
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
In case the macro is not available we now define it on our own in the utils.
|
||||
|
||||
Signed-off-by: Alexander Miroshnichenko <alex@millerson.name>
|
||||
---
|
||||
pinns/src/utils.h | 11 +++++++++++
|
||||
1 file changed, 11 insertions(+)
|
||||
|
||||
diff --git a/pinns/src/utils.h b/pinns/src/utils.h
|
||||
index 2bb0479c05cf..c213320bfd4d 100644
|
||||
--- a/pinns/src/utils.h
|
||||
+++ b/pinns/src/utils.h
|
||||
@@ -11,6 +11,17 @@
|
||||
#include <syslog.h>
|
||||
#include <unistd.h>
|
||||
|
||||
+#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
|
||||
+
|
||||
#define _pexit(s) \
|
||||
do { \
|
||||
fprintf(stderr, "[pinns:e]: %s: %s\n", s, strerror(errno)); \
|
||||
--
|
||||
2.26.2
|
||||
|
Loading…
Reference in New Issue
Block a user