kumquat-buildroot/package/waffle/waffle.mk
Romain Naour 2b7b4506c8 package/waffle: new package
waffle has four "backends", each having their own dependencies.
At least one "backend" must be enabled, otherwise Waffle will refuse to
build. The "backends" are:

 - glx, which needs full OpenGL + x11-xcb
 - wayland, which needs wayland-client, wayland-egl and EGL
 - x11-egl, which needs x11-xcb and EGL
 - gbm, which needs gbm, libudev and EGL

Backport an upstream patch fixing a build issue with musl toolchains.
Add a new patch fixing build with Wayand without X11.

Signed-off-by: Romain Naour <romain.naour@gmail.com>
[Thomas: drop GLES dependency, it is not mandatory.]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-10-09 21:54:57 +02:00

49 lines
1.3 KiB
Makefile

################################################################################
#
# waffle
#
################################################################################
WAFFLE_VERSION = v1.5.2
WAFFLE_SITE = $(call github,waffle-gl,waffle,$(WAFFLE_VERSION))
WAFFLE_INSTALL_STAGING = YES
WAFFLE_LICENSE = BSD-2-Clause
WAFFLE_LICENSE_FILES = LICENSE.txt
WAFFLE_DEPENDENCIES = host-pkgconf
WAFFLE_CONF_OPTS = -Dwaffle_build_tests=OFF \
-Dwaffle_build_examples=OFF \
-Dwaffle_build_manpages=OFF \
-Dwaffle_build_htmldocs=OFF
ifeq ($(BR2_PACKAGE_WAFFLE_SUPPORTS_WAYLAND),y)
WAFFLE_DEPENDENCIES += libegl wayland
WAFFLE_CONF_OPTS += -Dwaffle_has_wayland=ON
else
WAFFLE_CONF_OPTS += -Dwaffle_has_wayland=OFF
endif
ifeq ($(BR2_PACKAGE_WAFFLE_SUPPORTS_X11_EGL),y)
WAFFLE_DEPENDENCIES += libegl libxcb xlib_libX11
WAFFLE_CONF_OPTS += -Dwaffle_has_x11_egl=ON
else
WAFFLE_CONF_OPTS += -Dwaffle_has_x11_egl=OFF
endif
ifeq ($(BR2_PACKAGE_WAFFLE_SUPPORTS_GLX),y)
WAFFLE_DEPENDENCIES += libgl libxcb xlib_libX11
WAFFLE_CONF_OPTS += -Dwaffle_has_glx=ON
else
WAFFLE_CONF_OPTS += -Dwaffle_has_glx=OFF
endif
ifeq ($(BR2_PACKAGE_WAFFLE_SUPPORTS_GBM),y)
WAFFLE_DEPENDENCIES += libegl udev
WAFFLE_CONF_OPTS += -Dwaffle_has_gbm=ON
else
WAFFLE_CONF_OPTS += -Dwaffle_has_gbm=OFF
endif
$(eval $(cmake-package))