Skip to contentSkip to conversation

wxwidgets: Fix build without x11 and with opengl DISTRO_FEATURES

PATCH In review Marek Vasut 2 participants 3 messages Apr 11, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 wxwidgets: Fix build without x11 and with opengl DISTRO_FEATURES

In case DISTRO_FEATURES contains both 'x11' and 'opengl', which is a valid use case for systems using e.g. WL instead, the PACKAGECONFIG of this recipe is expanded to 'no_gui opengl', and the 'no_gui' option conflicts with 'opengl'.

Adjust the default PACKAGECONFIG such that 'opengl' is added only in case the 'gtk' GUI option is added, and not when the 'no_gui' option is added.

---
 meta-oe/recipes-extended/wxwidgets/wxwidgets_3.1.5.bb | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
meta-oe/recipes-extended/wxwidgets/wxwidgets_3.1.5.bb +1 -2
index e82143040..0c0c8417b 100644
@@ -44,8 +44,7 @@ EXTRA_OECMAKE:append:libc-musl = " \
 "
 
 # All toolkit-configs except 'no_gui' require x11 explicitly (see toolkit.cmake)
-PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk', 'no_gui', d)} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'opengl', d)} \
+PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk ' + bb.utils.filter('DISTRO_FEATURES', 'opengl', d), 'no_gui', d)} \
 "
 
 PACKAGECONFIG:remove:class-native = "opengl"
Signature · 1 line
2.35.1
#1 lore raw

There is already a patch staged in master-next

https://lists.openembedded.org/g/openembedded-devel/message/96479

does that solve the problem?

Quoted 32 lines · Marek Vasut

In case DISTRO_FEATURES contains both 'x11' and 'opengl', which is a valid use case for systems using e.g. WL instead, the PACKAGECONFIG of this recipe is expanded to 'no_gui opengl', and the 'no_gui' option conflicts with 'opengl'.

Adjust the default PACKAGECONFIG such that 'opengl' is added only in case the 'gtk' GUI option is added, and not when the 'no_gui' option is added.

---
 meta-oe/recipes-extended/wxwidgets/wxwidgets_3.1.5.bb | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
meta-oe/recipes-extended/wxwidgets/wxwidgets_3.1.5.bb +1 -3
index e82143040..0c0c8417b 100644
@@ -44,8 +44,7 @@ EXTRA_OECMAKE:append:libc-musl = " \
 "
 
 # All toolkit-configs except 'no_gui' require x11 explicitly (see toolkit.cmake)
-PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk', 'no_gui', d)} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'opengl', d)} \
+PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk ' + bb.utils.filter('DISTRO_FEATURES', 'opengl', d), 'no_gui', d)} \
 "
 
 PACKAGECONFIG:remove:class-native = "opengl"
--

2.35.1