diff options
| author | Tom Hochstein <tom.hochstein@nxp.com> | 2022-09-19 13:27:05 -0500 |
|---|---|---|
| committer | Tom Hochstein <tom.hochstein@nxp.com> | 2022-09-21 14:20:18 -0500 |
| commit | 0afe904e6bb501816ffc6cf0a7c136d7d46b144e (patch) | |
| tree | 1017ad8e0c07ca4bc69f9f067d65e28a6cd91099 | |
| parent | 77a4c34155fa0eb46350e1e46ae8c5138b6117d5 (diff) | |
| download | meta-freescale-0afe904e6bb501816ffc6cf0a7c136d7d46b144e.tar.gz | |
imx-gpu-viv: Add support for i.MX 8 without Wayland
This configuration is experimental and has never been fully tested.
Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
| -rw-r--r-- | recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc | 41 |
1 files changed, 25 insertions, 16 deletions
diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc b/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc index 4abab088a..e353b553f 100644 --- a/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc +++ b/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc | |||
| @@ -59,9 +59,7 @@ RPROVIDES:${PN}:imxgpu3d += "imx-gpu-viv" | |||
| 59 | 59 | ||
| 60 | PE = "1" | 60 | PE = "1" |
| 61 | 61 | ||
| 62 | inherit fsl-eula-unpack features_check | 62 | inherit fsl-eula-unpack |
| 63 | |||
| 64 | REQUIRED_DISTRO_FEATURES:mx8-nxp-bsp = "wayland" | ||
| 65 | 63 | ||
| 66 | SRC_URI = "${FSL_MIRROR}/${BPN}-${PV}.bin;fsl-eula=true" | 64 | SRC_URI = "${FSL_MIRROR}/${BPN}-${PV}.bin;fsl-eula=true" |
| 67 | 65 | ||
| @@ -175,6 +173,7 @@ do_install () { | |||
| 175 | # Use vulkan header from vulkan-headers recipe to support vkmark | 173 | # Use vulkan header from vulkan-headers recipe to support vkmark |
| 176 | rm -rf ${D}${includedir}/vulkan/ | 174 | rm -rf ${D}${includedir}/vulkan/ |
| 177 | 175 | ||
| 176 | # Install SOC-specific drivers | ||
| 178 | if [ -d ${S}/gpu-core/usr/lib/${IMX_SOC} ]; then | 177 | if [ -d ${S}/gpu-core/usr/lib/${IMX_SOC} ]; then |
| 179 | cp -r ${S}/gpu-core/usr/lib/${IMX_SOC}/* ${D}${libdir} | 178 | cp -r ${S}/gpu-core/usr/lib/${IMX_SOC}/* ${D}${libdir} |
| 180 | fi | 179 | fi |
| @@ -184,28 +183,38 @@ do_install () { | |||
| 184 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/gbm.pc ${D}${libdir}/pkgconfig/gbm.pc | 183 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/gbm.pc ${D}${libdir}/pkgconfig/gbm.pc |
| 185 | fi | 184 | fi |
| 186 | 185 | ||
| 186 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/glesv1_cm.pc ${D}${libdir}/pkgconfig/glesv1_cm.pc | ||
| 187 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/glesv2.pc ${D}${libdir}/pkgconfig/glesv2.pc | ||
| 188 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/vg.pc ${D}${libdir}/pkgconfig/vg.pc | ||
| 189 | |||
| 190 | # Install backend-specific drivers | ||
| 187 | if [ "${BACKEND}" = "wayland" ]; then | 191 | if [ "${BACKEND}" = "wayland" ]; then |
| 192 | # Wayland backend | ||
| 188 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/egl_wayland.pc ${D}${libdir}/pkgconfig/egl.pc | 193 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/egl_wayland.pc ${D}${libdir}/pkgconfig/egl.pc |
| 189 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/glesv1_cm.pc ${D}${libdir}/pkgconfig/glesv1_cm.pc | 194 | cp -r ${S}/gpu-core/usr/lib/wayland/* ${D}${libdir} |
| 190 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/glesv2.pc ${D}${libdir}/pkgconfig/glesv2.pc | 195 | elif [ "${IS_MX8}" != "1" ]; then |
| 191 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/vg.pc ${D}${libdir}/pkgconfig/vg.pc | 196 | # Framebuffer backend for i.MX 6 and 7 |
| 192 | else | ||
| 193 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/glesv1_cm.pc ${D}${libdir}/pkgconfig/glesv1_cm.pc | ||
| 194 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/glesv2.pc ${D}${libdir}/pkgconfig/glesv2.pc | ||
| 195 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/vg.pc ${D}${libdir}/pkgconfig/vg.pc | ||
| 196 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/egl_linuxfb.pc ${D}${libdir}/pkgconfig/egl.pc | 197 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/egl_linuxfb.pc ${D}${libdir}/pkgconfig/egl.pc |
| 198 | cp -r ${S}/gpu-core/usr/lib/fb/* ${D}${libdir} | ||
| 199 | else | ||
| 200 | # Framebuffer backend for i.MX 8 and beyond | ||
| 201 | install -m 0644 ${S}/gpu-core/usr/lib/pkgconfig/egl.pc ${D}${libdir}/pkgconfig/egl.pc | ||
| 202 | cp -r ${S}/gpu-core/usr/lib/wayland/* ${D}${libdir} | ||
| 203 | rm -rf \ | ||
| 204 | ${D}${libdir}/libVDK.so* \ | ||
| 205 | ${D}/opt/viv_samples/es20 \ | ||
| 206 | ${D}/opt/viv_samples/tiger \ | ||
| 207 | ${D}/opt/viv_samples/vdk | ||
| 208 | fi | ||
| 209 | if [ "${BACKEND}" = "wayland" ] && [ "${IS_MX8}" != "1" ]; then | ||
| 210 | # Special case for libVDK on Wayland backend, deliver fb library as well. | ||
| 211 | cp ${S}/gpu-core/usr/lib/fb/libVDK.so.1.2.0 ${D}${libdir}/libVDK-fb.so.1.2.0 | ||
| 197 | fi | 212 | fi |
| 198 | 213 | ||
| 199 | # Install Vendor ICDs for OpenCL's installable client driver loader (ICDs Loader) | 214 | # Install Vendor ICDs for OpenCL's installable client driver loader (ICDs Loader) |
| 200 | install -d ${D}${sysconfdir}/OpenCL/vendors/ | 215 | install -d ${D}${sysconfdir}/OpenCL/vendors/ |
| 201 | install -m 0644 ${S}/gpu-core/etc/Vivante.icd ${D}${sysconfdir}/OpenCL/vendors/Vivante.icd | 216 | install -m 0644 ${S}/gpu-core/etc/Vivante.icd ${D}${sysconfdir}/OpenCL/vendors/Vivante.icd |
| 202 | 217 | ||
| 203 | # Handle backend specific drivers | ||
| 204 | cp -r ${S}/gpu-core/usr/lib/${BACKEND}/* ${D}${libdir} | ||
| 205 | if [ "${BACKEND}" = "wayland" ] && [ "${IS_MX8}" != "1" ]; then | ||
| 206 | # Special case for libVDK on Wayland backend, deliver fb library as well. | ||
| 207 | cp ${S}/gpu-core/usr/lib/fb/libVDK.so.1.2.0 ${D}${libdir}/libVDK-fb.so.1.2.0 | ||
| 208 | fi | ||
| 209 | if [ "${IS_MX8}" = "1" ]; then | 218 | if [ "${IS_MX8}" = "1" ]; then |
| 210 | # Rename the vulkan implementation library which is wrapped by the vulkan-loader | 219 | # Rename the vulkan implementation library which is wrapped by the vulkan-loader |
| 211 | # library of the same name | 220 | # library of the same name |
