@@ -23,7 +23,7 @@ S = "${WORKDIR}/git"
X11_DEPS = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/libx11 libxrender libglu', '', d)}"
X11_RDEPS = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'mesa-demos', '', d)}"
-DEPENDS = "libpng waffle libxkbcommon python3-mako-native python3-numpy-native python3-six-native virtual/egl wayland-native wayland-protocols"
+DEPENDS = "libpng waffle libxkbcommon python3-mako-native python3-numpy-native python3-six-native virtual/egl"
inherit cmake pkgconfig python3native features_check bash-completion
@@ -36,12 +36,16 @@ REQUIRED_DISTRO_FEATURES += "opengl"
export TEMP = "${B}/temp/"
do_compile[dirs] =+ "${B}/temp/"
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11 glx', '', d)}"
+PACKAGECONFIG ??= " \
+ ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11 glx', '', d)} \
+ ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland', '', d)} \
+"
PACKAGECONFIG[freeglut] = "-DPIGLIT_USE_GLUT=1,-DPIGLIT_USE_GLUT=0,freeglut,"
PACKAGECONFIG[glx] = "-DPIGLIT_BUILD_GLX_TESTS=ON,-DPIGLIT_BUILD_GLX_TESTS=OFF"
PACKAGECONFIG[opencl] = "-DPIGLIT_BUILD_CL_TESTS=ON,-DPIGLIT_BUILD_CL_TESTS=OFF,virtual/opencl-icd"
PACKAGECONFIG[x11] = "-DPIGLIT_USE_X11=1 -DPIGLIT_BUILD_GL_TESTS=ON -DPIGLIT_BUILD_DMA_BUF_TESTS=ON,-DPIGLIT_USE_X11=0 -DPIGLIT_BUILD_GL_TESTS=OFF -DPIGLIT_BUILD_DMA_BUF_TESTS=OFF,${X11_DEPS}, ${X11_RDEPS}"
PACKAGECONFIG[vulkan] = "-DPIGLIT_BUILD_VK_TESTS=ON,-DPIGLIT_BUILD_VK_TESTS=OFF,glslang-native vulkan-loader,glslang"
+PACKAGECONFIG[wayland] = "-DPIGLIT_USE_WAYLAND=1,-DPIGLIT_USE_WAYLAND=0,wayland-native wayland wayland-protocols"
export PIGLIT_BUILD_DIR = "../../../../git"
After the recent piglit update it fails X11 builds reporting that it can not find wayland-client package. Commit 9662bdabf3f6 ("piglit: upgrade 22eaf6a91c -> c11c9374c1") has added wayland-related dependencies to the recipe's DEPENDS variable, but it seems it missed the target wayland pacakge, making cross-compilation of piglit fail when building X11-targeted configurations. Pushing more and more wayland dependencies to a generic build doesn't seem to be a good idea, so introduce "wayland" PACKAGECONFIG option, move existing wayland-related dependencies to be guarded by it and add dependency on the wayland package. Suggested-by: Alexander Kanavin <alex.kanavin@gmail.com> Fixes: 9662bdabf3f6 ("piglit: upgrade 22eaf6a91c -> c11c9374c1") Cc: Trevor Gamblin <tgamblin@baylibre.com> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> --- Changes since v1: - Move wayland dependencies to PACKAGECONFIG[wayland] (Alexander) --- meta/recipes-graphics/piglit/piglit_git.bb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)