diff options
author | Khem Raj <raj.khem@gmail.com> | 2024-02-13 09:01:08 -0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-02-14 13:52:20 +0000 |
commit | 62885b6943763bf093dbb3c4b9ea1b30d0f51966 (patch) | |
tree | 835b89218700e144ea3beaa057f57ba5c4ebbbd7 /meta/recipes-graphics | |
parent | c100c709e746e7b7301c5e01cbf43572a225f00e (diff) | |
download | openembedded-core-contrib-62885b6943763bf093dbb3c4b9ea1b30d0f51966.tar.gz |
piglit: Fix build with musl
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-graphics')
-rw-r--r-- | meta/recipes-graphics/piglit/piglit/0001-utils-Include-libgen.h-on-musl-linux-systems.patch | 31 | ||||
-rw-r--r-- | meta/recipes-graphics/piglit/piglit_git.bb | 1 |
2 files changed, 32 insertions, 0 deletions
diff --git a/meta/recipes-graphics/piglit/piglit/0001-utils-Include-libgen.h-on-musl-linux-systems.patch b/meta/recipes-graphics/piglit/piglit/0001-utils-Include-libgen.h-on-musl-linux-systems.patch new file mode 100644 index 0000000000..35e919e552 --- /dev/null +++ b/meta/recipes-graphics/piglit/piglit/0001-utils-Include-libgen.h-on-musl-linux-systems.patch @@ -0,0 +1,31 @@ +From 232a67b651ccb415b7d4d47584613359b7ebd920 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Tue, 13 Feb 2024 08:53:37 -0800 +Subject: [PATCH] utils: Include libgen.h on musl/linux systems + +musl does not provide GNU basename like string.h on glibc based systems +does, it does provide the POSIX compliant basename function therefore +allow to include libgen.h on non-glibc based linux systems + +Upstream-Status: Submitted [https://gitlab.freedesktop.org/mesa/piglit/-/merge_requests/877] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + tests/util/piglit-util.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/util/piglit-util.h b/tests/util/piglit-util.h +index 4d3606c70..fdfd903b3 100644 +--- a/tests/util/piglit-util.h ++++ b/tests/util/piglit-util.h +@@ -52,7 +52,7 @@ extern "C" { + #include <math.h> + #include <float.h> + +-#if defined(__APPLE__) || defined(__MINGW32__) ++#if defined(__APPLE__) || defined(__MINGW32__) || (defined(__linux__) && !defined(__GLIBC__)) + # include "libgen.h" // for basename + #elif defined(_MSC_VER) + +-- +2.43.1 + diff --git a/meta/recipes-graphics/piglit/piglit_git.bb b/meta/recipes-graphics/piglit/piglit_git.bb index 1bc3b784c7..ab749f7867 100644 --- a/meta/recipes-graphics/piglit/piglit_git.bb +++ b/meta/recipes-graphics/piglit/piglit_git.bb @@ -10,6 +10,7 @@ SRC_URI = "git://gitlab.freedesktop.org/mesa/piglit.git;protocol=https;branch=ma file://0002-cmake-use-proper-WAYLAND_INCLUDE_DIRS-variable.patch \ file://0003-tests-util-piglit-shader.c-do-not-hardcode-build-pat.patch \ file://0001-tests-Fix-narrowing-errors-seen-with-clang.patch \ + file://0001-utils-Include-libgen.h-on-musl-linux-systems.patch \ " UPSTREAM_CHECK_COMMITS = "1" |