summaryrefslogtreecommitdiffstats
path: root/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch')
-rw-r--r--meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch b/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch
new file mode 100644
index 000000000..32714038b
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch
@@ -0,0 +1,33 @@
+From 06011ce55b1e892e863568a73d64eebc6389544f Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 13 Jul 2017 17:14:05 -0700
+Subject: [PATCH] util.h: include <sys/reg.h> when libc != glibc
+
+For musl libc it is required to include <sys/reg.h> to
+have __WORDSIZE defined to e.g. 32 for arm*-musl.
+
+Taken from void-linux
+https://github.com/voidlinux/void-packages/blob/master/srcpkgs/dracut/patches/musl-__wordsize.patch
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ install/util.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/install/util.h b/install/util.h
+index 2ad3254d..062626ec 100644
+--- a/install/util.h
++++ b/install/util.h
+@@ -36,6 +36,9 @@
+ #include <sys/stat.h>
+ #include <dirent.h>
+ #include <sys/resource.h>
++#if !defined(__GLIBC__)
++#include <sys/reg.h>
++#endif
+
+ #include "macro.h"
+
+--
+2.13.2
+
OpenPOWER on IntegriCloud