summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2017-07-13 22:40:11 -0700
committerMartin Jansa <Martin.Jansa@gmail.com>2017-07-24 18:57:35 +0200
commit606e9b29eccfc5a61d8f58ef460da5e93119dd9c (patch)
tree90b0a4357731141235f8fee1249df0d8fa1a847c
parentb97358d5a3568deb2a5e939019bb2acef053e53f (diff)
downloadmeta-openembedded-606e9b29eccfc5a61d8f58ef460da5e93119dd9c.tar.gz
dracut: Upgrade to 045
Fix build on musl while here Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-rw-r--r--meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch33
-rw-r--r--meta-initramfs/recipes-devtools/dracut/dracut_git.bb19
2 files changed, 46 insertions, 6 deletions
diff --git a/meta-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch b/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-initramfs/recipes-devtools/dracut/dracut/0001-util.h-include-sys-reg.h-when-libc-glibc.patch
@@ -0,0 +1,33 @@
1From 06011ce55b1e892e863568a73d64eebc6389544f Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Thu, 13 Jul 2017 17:14:05 -0700
4Subject: [PATCH] util.h: include <sys/reg.h> when libc != glibc
5
6For musl libc it is required to include <sys/reg.h> to
7have __WORDSIZE defined to e.g. 32 for arm*-musl.
8
9Taken from void-linux
10https://github.com/voidlinux/void-packages/blob/master/srcpkgs/dracut/patches/musl-__wordsize.patch
11
12Signed-off-by: Khem Raj <raj.khem@gmail.com>
13---
14 install/util.h | 3 +++
15 1 file changed, 3 insertions(+)
16
17diff --git a/install/util.h b/install/util.h
18index 2ad3254d..062626ec 100644
19--- a/install/util.h
20+++ b/install/util.h
21@@ -36,6 +36,9 @@
22 #include <sys/stat.h>
23 #include <dirent.h>
24 #include <sys/resource.h>
25+#if !defined(__GLIBC__)
26+#include <sys/reg.h>
27+#endif
28
29 #include "macro.h"
30
31--
322.13.2
33
diff --git a/meta-initramfs/recipes-devtools/dracut/dracut_git.bb b/meta-initramfs/recipes-devtools/dracut/dracut_git.bb
index b91f3fae2..09c86d0b7 100644
--- a/meta-initramfs/recipes-devtools/dracut/dracut_git.bb
+++ b/meta-initramfs/recipes-devtools/dracut/dracut_git.bb
@@ -5,13 +5,18 @@ LICENSE = "GPLv2"
5LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 5LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
6 6
7PE = "1" 7PE = "1"
8PV = "044+git${SRCREV}" 8PV = "045+git${SRCREV}"
9 9
10# v044 tag 10# v045 tag
11SRCREV = "1bc3e733f96033a508841e97fe08da7a12851782" 11SRCREV = "39c9b67f86145953aa30def9d77c68597a4ccfe8"
12SRC_URI = "git://git.kernel.org/pub/scm/boot/dracut/dracut.git;protocol=http" 12SRC_URI = "git://git.kernel.org/pub/scm/boot/dracut/dracut.git;protocol=http \
13 file://0001-util.h-include-sys-reg.h-when-libc-glibc.patch \
14 "
13 15
14inherit bash-completion 16DEPENDS += "kmod"
17DEPENDS_append_libc-musl = " fts"
18
19inherit bash-completion pkgconfig
15 20
16S = "${WORKDIR}/git" 21S = "${WORKDIR}/git"
17 22
@@ -30,7 +35,9 @@ EXTRA_OECONF = "--prefix=${prefix} \
30PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" 35PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
31PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,,,systemd" 36PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,,,systemd"
32 37
33EXTRA_OEMAKE += 'libdir=${prefix}/lib' 38EXTRA_OEMAKE += 'libdir=${prefix}/lib LDLIBS="${LDLIBS}"'
39
40LDLIBS_append_libc-musl = " -lfts"
34 41
35do_configure() { 42do_configure() {
36 ./configure ${EXTRA_OECONF} 43 ./configure ${EXTRA_OECONF}