diff options
author | Khem Raj <raj.khem@gmail.com> | 2024-03-25 08:55:39 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-04-16 07:38:36 +0100 |
commit | b3f75f7926db2a616a49650ac04befa755c8dd8f (patch) | |
tree | 90ba28f2c75b16ea9c2b982be0765d78d906b90a /meta/recipes-extended/mdadm | |
parent | 952a2a94901ea6e9416e517e9f6c97dbc7e3bb2d (diff) | |
download | openembedded-core-b3f75f7926db2a616a49650ac04befa755c8dd8f.tar.gz |
mdadm: Fix build with new musl
new musl has removed basename prototype from string.h
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/mdadm')
-rw-r--r-- | meta/recipes-extended/mdadm/files/0001-include-libgen.h-for-basename-API.patch | 56 | ||||
-rw-r--r-- | meta/recipes-extended/mdadm/mdadm_4.3.bb | 1 |
2 files changed, 57 insertions, 0 deletions
diff --git a/meta/recipes-extended/mdadm/files/0001-include-libgen.h-for-basename-API.patch b/meta/recipes-extended/mdadm/files/0001-include-libgen.h-for-basename-API.patch new file mode 100644 index 0000000000..70be43c15e --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-include-libgen.h-for-basename-API.patch @@ -0,0 +1,56 @@ +From 7759ceda978aba38861d4846d0c1657465b72f04 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Sun, 24 Mar 2024 23:13:32 -0700 +Subject: [PATCH] include libgen.h for basename API + +Musl does no more provide it via string.h therefore builds with newer +compilers e.g. clang-18 fails due to missing prototype for basename +therefore add libgen.h to included headers list + +Upstream-Status: Submitted [https://lore.kernel.org/linux-raid/20240325061537.275811-1-raj.khem@gmail.com/T/#u] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + Monitor.c | 1 + + platform-intel.c | 1 + + super-intel.c | 1 + + 3 files changed, 3 insertions(+) + +diff --git a/Monitor.c b/Monitor.c +index 824a69f..e3942e1 100644 +--- a/Monitor.c ++++ b/Monitor.c +@@ -26,6 +26,7 @@ + #include "udev.h" + #include "md_p.h" + #include "md_u.h" ++#include <libgen.h> + #include <sys/wait.h> + #include <limits.h> + #include <syslog.h> +diff --git a/platform-intel.c b/platform-intel.c +index ac282bc..5d6687d 100644 +--- a/platform-intel.c ++++ b/platform-intel.c +@@ -19,6 +19,7 @@ + #include "mdadm.h" + #include "platform-intel.h" + #include "probe_roms.h" ++#include <libgen.h> + #include <stdio.h> + #include <stdlib.h> + #include <string.h> +diff --git a/super-intel.c b/super-intel.c +index dbea235..881dbda 100644 +--- a/super-intel.c ++++ b/super-intel.c +@@ -23,6 +23,7 @@ + #include "dlink.h" + #include "sha1.h" + #include "platform-intel.h" ++#include <libgen.h> + #include <values.h> + #include <scsi/sg.h> + #include <ctype.h> +-- +2.44.0 + diff --git a/meta/recipes-extended/mdadm/mdadm_4.3.bb b/meta/recipes-extended/mdadm/mdadm_4.3.bb index fc58fcb86c..228fc6f84e 100644 --- a/meta/recipes-extended/mdadm/mdadm_4.3.bb +++ b/meta/recipes-extended/mdadm/mdadm_4.3.bb @@ -23,6 +23,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://0001-restripe.c-Use-_FILE_OFFSET_BITS-to-enable-largefile.patch \ file://0002-Create.c-include-linux-falloc.h-for-FALLOC_FL_ZERO_R.patch \ file://0001-util.c-add-limits.h-include-for-NAME_MAX-definition.patch \ + file://0001-include-libgen.h-for-basename-API.patch \ " SRC_URI[sha256sum] = "416727ae1f1080ea6e3090cea36dd076826fc369151e36ab736557ba92196f9f" |