summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGyorgy Sarvari <skandigraun@gmail.com>2025-02-16 15:08:12 +0100
committerKhem Raj <raj.khem@gmail.com>2025-02-16 08:10:20 -0800
commitbdd2b5340853228e5b9b1ee39819b7e65e74b1d7 (patch)
tree693a1638e2569f1b3f975d04aa4639159d034a36
parent964f55887ae464e9053fc484d55f7a38f5373b7c (diff)
downloadmeta-openembedded-bdd2b5340853228e5b9b1ee39819b7e65e74b1d7.tar.gz
libplacebo: fix demos PACKAGECONFIG
In case the demos PACKAGECONFIG is enabled, linking fails with the following error: | /usr/src/debug/libplacebo/7.349.0/demos/plplay.c:669:(.text.startup+0x90): undefined reference to `parse_args' | collect2: error: ld returned 1 exit status The implementation of the missing function is guarded erroneously by an ifdef flag (HAVE_NUKLEAR, which is only true in case headers from the nuklear library are present - but in this recipe they are not included). This patch moves the implementation of this function outside of the ifdef to avoid the build failure. Signed-off-by: Gyorgy Sarvari <skandigraun@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-oe/recipes-multimedia/mplayer/libplacebo/0001-Fix-compiling-demos-without-nuklear.patch40
-rw-r--r--meta-oe/recipes-multimedia/mplayer/libplacebo_7.349.0.bb3
2 files changed, 42 insertions, 1 deletions
diff --git a/meta-oe/recipes-multimedia/mplayer/libplacebo/0001-Fix-compiling-demos-without-nuklear.patch b/meta-oe/recipes-multimedia/mplayer/libplacebo/0001-Fix-compiling-demos-without-nuklear.patch
new file mode 100644
index 0000000000..bd849a75dd
--- /dev/null
+++ b/meta-oe/recipes-multimedia/mplayer/libplacebo/0001-Fix-compiling-demos-without-nuklear.patch
@@ -0,0 +1,40 @@
1From ad0bbc5099d99bbb0c914b39cb5ab4920fd6eeda Mon Sep 17 00:00:00 2001
2From: Gyorgy Sarvari <skandigraun@gmail.com>
3Date: Sun, 16 Feb 2025 14:23:40 +0100
4Subject: [PATCH] Fix compiling demos without nuklear
5
6Demos can't be compiled if nuklear headers are not present, because
7the implementation of parse_args function is guarded by HAVE_NUKLEAR macro.
8
9To allow compiling demos without the Nuklear headers, move the implementation
10outside of this ifdef.
11
12Upstream-Status: Submitted [https://github.com/haasn/libplacebo/pull/315]
13---
14 demos/settings.c | 6 +++---
15 1 file changed, 3 insertions(+), 3 deletions(-)
16
17diff --git a/demos/settings.c b/demos/settings.c
18index 197e8b7e..73f0e5b9 100644
19--- a/demos/settings.c
20+++ b/demos/settings.c
21@@ -14,9 +14,6 @@
22 #define PL_BASENAME basename
23 #endif
24
25-#ifdef HAVE_NUKLEAR
26-#include "ui.h"
27-
28 bool parse_args(struct plplay_args *args, int argc, char *argv[])
29 {
30 static struct option long_options[] = {
31@@ -89,6 +86,9 @@ error:
32 return false;
33 }
34
35+#ifdef HAVE_NUKLEAR
36+#include "ui.h"
37+
38 static void add_hook(struct plplay *p, const struct pl_hook *hook, const char *path)
39 {
40 if (!hook)
diff --git a/meta-oe/recipes-multimedia/mplayer/libplacebo_7.349.0.bb b/meta-oe/recipes-multimedia/mplayer/libplacebo_7.349.0.bb
index a5b38db335..aaeaad1455 100644
--- a/meta-oe/recipes-multimedia/mplayer/libplacebo_7.349.0.bb
+++ b/meta-oe/recipes-multimedia/mplayer/libplacebo_7.349.0.bb
@@ -5,7 +5,8 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=435ed639f84d4585d93824e7da3d85da"
5DEPENDS += "fastfloat glad-native python3-mako-native python3-jinja2-native vulkan-headers" 5DEPENDS += "fastfloat glad-native python3-mako-native python3-jinja2-native vulkan-headers"
6 6
7SRC_URI = "git://code.videolan.org/videolan/libplacebo.git;protocol=https;branch=v7.349 \ 7SRC_URI = "git://code.videolan.org/videolan/libplacebo.git;protocol=https;branch=v7.349 \
8 file://0001-meson-add-glslang-lib-for-15.0.0-linking.patch" 8 file://0001-meson-add-glslang-lib-for-15.0.0-linking.patch \
9 file://0001-Fix-compiling-demos-without-nuklear.patch"
9SRCREV = "1fd3c7bde7b943fe8985c893310b5269a09b46c5" 10SRCREV = "1fd3c7bde7b943fe8985c893310b5269a09b46c5"
10 11
11inherit meson pkgconfig 12inherit meson pkgconfig