MACHINE_GSTREAMER_1_0_PLUGIN_mx6q ?= "gstreamer1.0-plugins-imx-meta"
MACHINE_GSTREAMER_1_0_PLUGIN_mx6dl ?= "gstreamer1.0-plugins-imx-meta"
+# Determines if the SoC has support for Vivante kernel driver
+SOC_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT = "0"
+SOC_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT_mx6q = "1"
+SOC_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT_mx6dl = "1"
+SOC_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT_mx6sx = "1"
+SOC_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT_mx6sl = "1"
+
+# Handle Vivante kernel driver setting:
+# 0 - machine does not have Vivante GPU driver support
+# 1 - machine has Vivante GPU driver support
+MACHINE_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT ??= "${SOC_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT}"
+
# mx6 GPU libraries
PREFERRED_PROVIDER_virtual/egl_mx6q ?= "imx-gpu-viv"
PREFERRED_PROVIDER_virtual/egl_mx6dl ?= "imx-gpu-viv"
imx-gpu-viv-demos imx-gpu-viv-demos-dbg \
"
-# Skip package if it does not match the machine float-point type in use
python __anonymous () {
+ has_vivante_kernel_driver_support = (d.getVar('MACHINE_HAS_VIVANTE_KERNEL_DRIVER_SUPPORT', True) or '0')
+ if has_vivante_kernel_driver_support != '1':
+ raise bb.parse.SkipPackage('The kernel of machine needs to have Vivante kernel driver support for this recipe to be used.')
+
+ # Skip package if it does not match the machine float-point type in use
is_machine_hardfp = base_contains("TUNE_FEATURES", "callconvention-hard", True, False, d)
is_package_hardfp = d.getVar("PACKAGE_FP_TYPE", True) == "hardfp"
FILES_libgal-mx6 = "${libdir}/libGAL${SOLIBS} ${libdir}/libGAL_egl${SOLIBS}"
FILES_libgal-mx6-dev = "${libdir}/libGAL${SOLIBSDEV} ${includedir}/HAL"
FILES_libgal-mx6-dbg = "${libdir}/.debug/libGAL${SOLIBS}"
+RDEPENDS_libgal-mx6 += "kernel-module-imx-gpu-viv"
+INSANE_SKIP_libgal-mx6 += "build-deps"
FILES_libvsc-mx6 = "${libdir}/libVSC${SOLIBS}"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
-inherit kernel fsl-kernel-localversion
+inherit kernel fsl-kernel-localversion fsl-vivante-kernel-driver-handler
# Put a local version until we have a true SRCREV to point to
LOCALVERSION ?= ""