aboutsummaryrefslogtreecommitdiffstats
path: root/main/elfutils/musl-macros.patch
diff options
context:
space:
mode:
Diffstat (limited to 'main/elfutils/musl-macros.patch')
-rw-r--r--main/elfutils/musl-macros.patch77
1 files changed, 34 insertions, 43 deletions
diff --git a/main/elfutils/musl-macros.patch b/main/elfutils/musl-macros.patch
index 0d7ec4155ee..d1bf92eb665 100644
--- a/main/elfutils/musl-macros.patch
+++ b/main/elfutils/musl-macros.patch
@@ -1,5 +1,28 @@
---- a/src/arlib.h 2015-08-21 14:22:37.000000000 +0200
-+++ b/src/arlib.h 2015-11-20 08:02:55.153199611 +0100
+diff -ur elfutils-0.187.orig/lib/libeu.h elfutils-0.187/lib/libeu.h
+--- elfutils-0.187.orig/lib/libeu.h 2022-06-16 18:48:12.916472948 +0200
++++ elfutils-0.187/lib/libeu.h 2022-06-16 18:48:54.219839323 +0200
+@@ -31,6 +31,18 @@
+
+ #include <stddef.h>
+ #include <stdint.h>
++#include <unistd.h>
++#include <alloca.h>
++#include <string.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
+
+ extern void *xmalloc (size_t) __attribute__ ((__malloc__));
+ extern void *xcalloc (size_t, size_t) __attribute__ ((__malloc__));
+diff -ur elfutils-0.187.orig/src/arlib.h elfutils-0.187/src/arlib.h
+--- elfutils-0.187.orig/src/arlib.h 2022-06-16 18:48:12.919806284 +0200
++++ elfutils-0.187/src/arlib.h 2022-06-16 18:48:18.879811052 +0200
@@ -29,6 +29,16 @@
#include <stdint.h>
#include <sys/types.h>
@@ -17,11 +40,12 @@
/* State of -D/-U flags. */
extern bool arlib_deterministic_output;
---- a/src/elfcompress.c.orig 2016-04-02 12:51:26.903848894 +0200
-+++ b/src/elfcompress.c 2016-04-02 12:55:15.076996338 +0200
-@@ -35,6 +35,14 @@
- #include <gelf.h>
- #include "system.h"
+diff -ur elfutils-0.187.orig/src/elfcompress.c elfutils-0.187/src/elfcompress.c
+--- elfutils-0.187.orig/src/elfcompress.c 2022-06-16 18:48:12.919806284 +0200
++++ elfutils-0.187/src/elfcompress.c 2022-06-16 18:48:18.879811052 +0200
+@@ -37,6 +37,14 @@
+ #include "libeu.h"
+ #include "printversion.h"
+#if !defined(FNM_EXTMATCH)
+# define FNM_EXTMATCH 0
@@ -32,44 +56,11 @@
+#endif
+
/* Name and version of program. */
- static void print_version (FILE *stream, struct argp_state *state);
ARGP_PROGRAM_VERSION_HOOK_DEF = print_version;
-diff --git a/lib/libeu.h b/lib/libeu.h
-index 69fe3d7..e5c99b8 100644
---- a/lib/libeu.h
-+++ b/lib/libeu.h
-@@ -31,6 +31,27 @@
- #include <stddef.h>
- #include <stdint.h>
-+#include <unistd.h>
-+#include <alloca.h>
-+#include <string.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
-+
-+#ifndef strndupa
-+#define strndupa(s, n) \
-+ (__extension__ ({const char *__in = (s); \
-+ size_t __len = strnlen (__in, (n)) + 1; \
-+ char *__out = (char *) alloca (__len); \
-+ __out[__len-1] = '\0'; \
-+ (char *) memcpy (__out, __in, __len-1);}))
-+#endif
-
- extern void *xmalloc (size_t) __attribute__ ((__malloc__));
- extern void *xcalloc (size_t, size_t) __attribute__ ((__malloc__));
-diff --git a/src/strip.c b/src/strip.c
-index 48792a7..d2f0c60 100644
---- a/src/strip.c
-+++ b/src/strip.c
+diff -ur elfutils-0.187.orig/src/strip.c elfutils-0.187/src/strip.c
+--- elfutils-0.187.orig/src/strip.c 2022-06-16 18:48:12.919806284 +0200
++++ elfutils-0.187/src/strip.c 2022-06-16 18:48:18.879811052 +0200
@@ -46,6 +46,14 @@
#include <system.h>
#include <printversion.h>