diff options
author | Khem Raj <raj.khem@gmail.com> | 2024-03-25 17:56:27 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2024-03-25 18:52:52 -0700 |
commit | 6f4ed3a094e9fffb6ab1988d0f33df9430aad126 (patch) | |
tree | a909d01fcc9050968c612bacbba7591c4cf360e0 /meta-oe | |
parent | baf8e1e39b23e9271b1b8da16714d5d0b2c91d5d (diff) | |
download | meta-openembedded-6f4ed3a094e9fffb6ab1988d0f33df9430aad126.tar.gz |
uftrace: Fix build with musl >= 1.2.5
The famous basename API fallout
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe')
-rw-r--r-- | meta-oe/recipes-devtools/uftrace/uftrace/0001-include-libgen.h-for-basename.patch | 34 | ||||
-rw-r--r-- | meta-oe/recipes-devtools/uftrace/uftrace_0.15.2.bb | 3 |
2 files changed, 36 insertions, 1 deletions
diff --git a/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-libgen.h-for-basename.patch b/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-libgen.h-for-basename.patch new file mode 100644 index 0000000000..4844003517 --- /dev/null +++ b/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-libgen.h-for-basename.patch @@ -0,0 +1,34 @@ +From 8e4e5479cee153db7315d5134663fa87082b39fc Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Mon, 25 Mar 2024 17:46:24 -0700 +Subject: [PATCH] include libgen.h for basename + +basename prototype has been removed from string.h from latest musl [1] +compilers e.g. clang-18 flags the absense of prototype as error. therefore +include libgen.h for providing it. + +[1] https://git.musl-libc.org/cgit/musl/commit/?id=725e17ed6dff4d0cd22487bb64470881e86a92e7 + +Upstream-Status: Submitted [https://github.com/namhyung/uftrace/pull/1909] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + utils/utils.h | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/utils/utils.h b/utils/utils.h +index 69a6072b..60265431 100644 +--- a/utils/utils.h ++++ b/utils/utils.h +@@ -11,6 +11,9 @@ + + #include <ctype.h> + #include <endian.h> ++#ifndef __GLIBC__ ++#include <libgen.h> ++#endif + #include <limits.h> + #include <signal.h> + #include <stdbool.h> +-- +2.44.0 + diff --git a/meta-oe/recipes-devtools/uftrace/uftrace_0.15.2.bb b/meta-oe/recipes-devtools/uftrace/uftrace_0.15.2.bb index ff04d40eaf..60436025a3 100644 --- a/meta-oe/recipes-devtools/uftrace/uftrace_0.15.2.bb +++ b/meta-oe/recipes-devtools/uftrace/uftrace_0.15.2.bb @@ -11,7 +11,8 @@ DEPENDS:append:libc-musl = " argp-standalone" inherit autotools SRCREV = "9d8657e90b918994d7d2bcf6dd2cc7354c35a1b4" -SRC_URI = "git://github.com/namhyung/${BPN};branch=master;protocol=https" +SRC_URI = "git://github.com/namhyung/${BPN};branch=master;protocol=https \ + file://0001-include-libgen.h-for-basename.patch" S = "${WORKDIR}/git" LDFLAGS:append:libc-musl = " -largp" |