The new Xorg driver does not need a DRI library anymore, so we remove the xf86-dri-vivante recipe, but use the DRI code during the Xorg GPU driver build.
This change has been based on changes done in meta-fsl-bsp-release, 3.5.7 dylan branch, by Lauren Post <lauren.p...@freescale.com> and Evan Kotara <evan.kot...@freescale.com>. Change-Id: I3f666da817fb158b201dc169ae7862b199216ddd Signed-off-by: Otavio Salvador <ota...@ossystems.com.br> --- conf/machine/include/imx-base.inc | 2 - .../xf86-dri-vivante/fix-libdrm-link.patch | 33 --------- .../xorg-driver/xf86-dri-vivante_3.0.35-4.0.0.bb | 48 ------------- .../Makefile-fix-cross-compile.patch | 23 ++++++ ...on-t-force-things-decided-by-build-system.patch | 82 ++++++++++++++++++++++ .../xf86-video-imxfb-vivante_3.0.35-4.0.0.bb | 54 -------------- ...xf86-video-imxfb-vivante_3.5.7-1.0.0-alpha.2.bb | 59 ++++++++++++++++ 7 files changed, 164 insertions(+), 137 deletions(-) delete mode 100644 recipes-graphics/xorg-driver/xf86-dri-vivante/fix-libdrm-link.patch delete mode 100644 recipes-graphics/xorg-driver/xf86-dri-vivante_3.0.35-4.0.0.bb create mode 100644 recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/Makefile-fix-cross-compile.patch create mode 100644 recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/build-Don-t-force-things-decided-by-build-system.patch delete mode 100644 recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.0.35-4.0.0.bb create mode 100644 recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.5.7-1.0.0-alpha.2.bb diff --git a/conf/machine/include/imx-base.inc b/conf/machine/include/imx-base.inc index cafdbf7..5d6243a 100644 --- a/conf/machine/include/imx-base.inc +++ b/conf/machine/include/imx-base.inc @@ -20,8 +20,6 @@ UBOOT_ENTRYPOINT_mx6 = "0x10008000" UBOOT_ENTRYPOINT_mx6sl = "0x80008000" UBOOT_ENTRYPOINT_vf60 = "0x80008000" -PREFERRED_VERSION_xserver-xorg_mx6 ?= "2:1.11.4" - XSERVER_DRIVER = "xf86-video-fbdev" XSERVER_DRIVER_mx5 = "xf86-video-imxfb" XSERVER_DRIVER_mx6 = "xf86-video-imxfb-vivante" diff --git a/recipes-graphics/xorg-driver/xf86-dri-vivante/fix-libdrm-link.patch b/recipes-graphics/xorg-driver/xf86-dri-vivante/fix-libdrm-link.patch deleted file mode 100644 index fe3e610..0000000 --- a/recipes-graphics/xorg-driver/xf86-dri-vivante/fix-libdrm-link.patch +++ /dev/null @@ -1,33 +0,0 @@ -This adds a missing link dependency on libdrm - -Upstream-Status: Pending -Signed-off-by: Otavio Salvador <ota...@ossystems.com.br> - -Index: DRI_1.10.4/configure.ac -=================================================================== ---- DRI_1.10.4.orig/configure.ac -+++ DRI_1.10.4/configure.ac -@@ -55,6 +55,7 @@ XORG_DRIVER_CHECK_EXT(XV, videoproto) - - # Checks for pkg-config packages - PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES]) -+PKG_CHECK_MODULES(LIBDRM, [libdrm >= 2.3.0]) - sdkdir=$(pkg-config --variable=sdkdir xorg-server) - - # Checks for libraries. -Index: DRI_1.10.4/src/Makefile.am -=================================================================== ---- DRI_1.10.4.orig/src/Makefile.am -+++ DRI_1.10.4/src/Makefile.am -@@ -11,9 +11,9 @@ - ############################################################################## - - --AM_CFLAGS = @XORG_CFLAGS@ -+AM_CFLAGS = @XORG_CFLAGS@ @LIBDRM_CFLAGS@ - libdri_la_LTLIBRARIES = libdri.la --libdri_la_LDFLAGS = -module -avoid-version -+libdri_la_LDFLAGS = -module -avoid-version @LIBDRM_LIBS@ - libdri_ladir = @moduledir@/extensions - libdri_la_SOURCES = \ - dri.c \ diff --git a/recipes-graphics/xorg-driver/xf86-dri-vivante_3.0.35-4.0.0.bb b/recipes-graphics/xorg-driver/xf86-dri-vivante_3.0.35-4.0.0.bb deleted file mode 100644 index c116d57..0000000 --- a/recipes-graphics/xorg-driver/xf86-dri-vivante_3.0.35-4.0.0.bb +++ /dev/null @@ -1,48 +0,0 @@ -# Copyright (C) 2012-2013 Freescale Semiconductor -# Copyright (C) 2012-2013 O.S. Systems Software LTDA. -# Released under the MIT license (see COPYING.MIT for the terms) - -LICENSE = "MIT" -SECTION = "x11/base" -DEPENDS = "virtual/xserver xf86-video-imxfb-vivante" -LIC_FILES_CHKSUM = "file://src/dri.h;enline=27;md5=1d0d59e1dc96f5197ea3a8b101bf1fcc" - -SRC_URI = "${FSL_MIRROR}/xserver-xorg-video-imx-viv-${PV}.tar.gz \ - file://fix-libdrm-link.patch" -SRC_URI[md5sum] = "5c5b5be029b077346610518bb729c012" -SRC_URI[sha256sum] = "c67249e68d4233eb1d0a5f337ded8f121dc61fa26fca102a00f93acc3e37ea0f" - -PE = "1" -PR = "r0" - -S = "${WORKDIR}/xserver-xorg-video-imx-viv-${PV}/DRI_1.10.4" - -inherit fsl-eula-unpack autotools pkgconfig - -EXTRA_OECONF_armv7a = " --enable-neon " -CFLAGS += " -I${STAGING_INCDIR}/xorg -DXSERVER_LIBPCIACCESS" - -do_install_append () { - # Install header files - install -d ${D}${includedir}/xorg - cp -axr ${S}/src/*.h ${D}${includedir}/xorg - find ${D}${includedir} -type f -exec chmod 660 {} \; - - # FIXME: don't install libtool (*.la) file - rm ${D}${libdir}/xorg/modules/extensions/*.la - - # FIXME: The Xorg driver has a hardcoded library name - mv ${D}${libdir}/xorg/modules/extensions/libdri.so \ - ${D}${libdir}/xorg/modules/extensions/libvivante_dri.so -} - -FILES_${PN}-dev += "${includedir}/xorg/*.h" -FILES_${PN} += " ${libdir}/xorg/modules/extensions/*.so" -FILES_${PN}-dbg += " ${libdir}/xorg/modules/extensions/.debug" - -RDEPENDS_${PN} += "xserver-xorg-extension-glx \ - xserver-xorg-extension-dri \ - xserver-xorg-extension-dri2" - -PACKAGE_ARCH = "${MACHINE_ARCH}" -COMPATIBLE_MACHINE = "(mx6)" diff --git a/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/Makefile-fix-cross-compile.patch b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/Makefile-fix-cross-compile.patch new file mode 100644 index 0000000..ce3a9ae --- /dev/null +++ b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/Makefile-fix-cross-compile.patch @@ -0,0 +1,23 @@ +diff --git a/EXA/src/makefile.linux b/EXA/src/makefile.linux +index 12cb8f3..005b002 100644 +--- a/EXA/src/makefile.linux ++++ b/EXA/src/makefile.linux +@@ -1,9 +1,6 @@ + + .PHONY: all clean install + +-CC := $(CROSS_COMPILE)gcc +-LD := $(CROSS_COMPILE)gcc +- + target := vivante_drv.so + + OBJS := vivante_gal/vivante_gal_blit.o \ +@@ -63,7 +60,7 @@ LFLAGS += -L$(sysroot)/usr/lib -lm -ldl -lGAL -Wl,-soname -Wl,vivante_drv.so + all: $(target) + + $(target): $(OBJS) +- $(LD) -shared -fPIC -o $(target) $(OBJS) $(LFLAGS) ++ $(CC) -shared -fPIC -o $(target) $(OBJS) $(LFLAGS) + + clean: + -@rm $(target) $(OBJS) diff --git a/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/build-Don-t-force-things-decided-by-build-system.patch b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/build-Don-t-force-things-decided-by-build-system.patch new file mode 100644 index 0000000..5fda33c --- /dev/null +++ b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante/build-Don-t-force-things-decided-by-build-system.patch @@ -0,0 +1,82 @@ +From bc46bc886c79246065cf779a7b4e197b80acd9b1 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador <ota...@ossystems.com.br> +Date: Thu, 18 Jul 2013 19:52:11 -0300 +Subject: [PATCH] build: Don't force things decided by build system + +The build system should't enforce build flags and linking flags which +are not really necessary so it build system can do the "Right Thing" +automatically. + +Upstream-Status: Pending + +Signed-off-by: Otavio Salvador <ota...@ossystems.com.br> +--- + DRI_1.10.4/src/makefile.linux | 20 +------------------- + EXA/src/makefile.linux | 9 +-------- + 2 files changed, 2 insertions(+), 27 deletions(-) + +diff --git a/DRI_1.10.4/src/makefile.linux b/DRI_1.10.4/src/makefile.linux +index 86aa903..9188432 100644 +--- a/DRI_1.10.4/src/makefile.linux ++++ b/DRI_1.10.4/src/makefile.linux +@@ -37,29 +37,11 @@ ifeq ($(SWAP_SINGLE_PARAMETER),1) + CFLAGS += -DSWAP_SINGLE_PARAMETER + endif + +-ifeq ($(BUILD_HARD_VFP),1) +-CFLAGS += -mfpu=neon -mfloat-abi=hard +-else +-CFLAGS += -mfpu=vfp -mfloat-abi=softfp +-endif +- + CFLAGS += -fvisibility=hidden -fPIC -DPIC + CFLAGS += -I. -I.. -I$(sysroot)/usr/include -I$(sysroot)/usr/include/xorg -I$(sysroot)/usr/include/$(PIXMAN) + CFLAGS += -I../../EXA/src/vivante_gal +-ifeq ($(YOCTO),1) +-# Yocto: compile will fail (does not support ldrex/strexeq/...) +-# specify armv6 to walkaround it +-# armv7: not supported by the toolchain +-CFLAGS += -march=armv6 +-else +-CFLAGS += -marm +-# -Wa,-mimplicit-it=thumb +-endif +- + +-#LFLAGS += -lGAL -lm -ldl -ldrm -lX11 -module -Wl,-soname -Wl,$(target) -Wl,-rpath,/usr/lib/xorg/modules/extensions +-#LFLAGS += -lGAL -lm -ldl -ldrm -lX11 -module -Wl,-soname -Wl,$(target) +-LFLAGS += -L$(sysroot)/usr/lib -lGAL -lm -ldl -ldrm -lX11 -Wl,-soname -Wl,$(target) ++LFLAGS += -lGAL -lm -ldl -ldrm -lX11 -Wl,-soname -Wl,$(target) + + all: $(target) + +diff --git a/EXA/src/makefile.linux b/EXA/src/makefile.linux +index eb56de5..bfaf314 100644 +--- a/EXA/src/makefile.linux ++++ b/EXA/src/makefile.linux +@@ -57,12 +57,6 @@ ifeq ($(BUSID_HAS_NUMBER),1) + CFLAGS += -DBUSID_HAS_NUMBER + endif + +-ifeq ($(BUILD_HARD_VFP),1) +-CFLAGS += -mfpu=neon -mfloat-abi=hard +-else +-CFLAGS += -mfpu=vfp -mfloat-abi=softfp +-endif +- + # macro FREESCALE_EXTENSION is reserved for future use + CFLAGS += -fvisibility=hidden -fPIC -DPIC -O2 -DFREESCALE_EXTENSION + CFLAGS += -I. -I.. -I$(sysroot)/usr/include -I$(sysroot)/usr/include/xorg -I$(sysroot)/usr/include/$(PIXMAN) +@@ -73,8 +67,7 @@ CFLAGS += -marm + #CFLAGS += -mimplicit-it=thumb + + LFLAGS += -fPIC +-#LFLAGS += -Wl,--no-allow-shlib-undefined -lX11 +-LFLAGS += -L$(sysroot)/usr/lib -lm -ldl -lGAL -Wl,-soname -Wl,vivante_drv.so ++LFLAGS += -lm -ldl -lGAL -Wl,-soname -Wl,vivante_drv.so + + + all: $(target) +-- +1.8.3.2 + diff --git a/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.0.35-4.0.0.bb b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.0.35-4.0.0.bb deleted file mode 100644 index dbaf2ab..0000000 --- a/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.0.35-4.0.0.bb +++ /dev/null @@ -1,54 +0,0 @@ -# Copyright (C) 2012-2013 Freescale Semiconductor -# Copyright (C) 2012-2013 O.S. Systems Software LTDA. -# Released under the MIT license (see COPYING.MIT for the terms) - -require recipes-graphics/xorg-driver/xorg-driver-video.inc - -PE = "3" -PR = "${INC_PR}.3" - -DEPENDS += "virtual/xserver virtual/libx11 virtual/libgal-x11 gpu-viv-bin-mx6q" - -LIC_FILES_CHKSUM = "file://src/vivante_fbdev/vivante.h;endline=19;md5=641ac6e6d013833e36290797f4d7089c" - -SRC_URI = "${FSL_MIRROR}/xserver-xorg-video-imx-viv-${PV}.tar.gz \ - file://Makefile.am-remove-prefixed-include-path.patch" -SRC_URI[md5sum] = "5c5b5be029b077346610518bb729c012" -SRC_URI[sha256sum] = "c67249e68d4233eb1d0a5f337ded8f121dc61fa26fca102a00f93acc3e37ea0f" - -EXTRA_OECONF_armv7a = " --enable-neon --disable-static" -CFLAGS += " -I${STAGING_INCDIR}/xorg -I${STAGING_INCDIR}/drm" -LDFLAGS += " -lGAL" - -S = "${WORKDIR}/xserver-xorg-video-imx-viv-${PV}/EXA/" - -do_compile_prepend () { - # FIXME: Allow build without depending on xserver-xorg - # as this is the is the only source dependency and - # by default Xorg does not install this header anyway. - cp ${S}/../DRI*/src/dri.h ${S}/../DRI*/src/sarea.h ${S}/src/vivante_fbdev/ -} - -do_install_append () { - install -d ${D}${includedir} - cp -axr ${S}/src/vivante_gal/vivante_priv.h ${D}${includedir} - cp -axr ${S}/src/vivante_gal/vivante_gal.h ${D}${includedir} - find ${D}${includedir} -type f -exec chmod 660 {} \; -} - -RDEPENDS_${PN} += "libvivante-dri-mx6 \ - xserver-xorg-module-exa \ - mesa-driver-swrast \ - xf86-dri-vivante" - -# Add the ABI dependency at package generation time, as otherwise bitbake will -# attempt to find a provider for it (and fail) when it does the parse. -# -# This version *must* be kept correct. -python populate_packages_prepend() { - pn = d.getVar("PN", True) - d.appendVar("RDEPENDS_" + pn, " xorg-abi-video-11") -} - -PACKAGE_ARCH = "${MACHINE_ARCH}" -COMPATIBLE_MACHINE = "(mx6)" diff --git a/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.5.7-1.0.0-alpha.2.bb b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.5.7-1.0.0-alpha.2.bb new file mode 100644 index 0000000..c65ad27 --- /dev/null +++ b/recipes-graphics/xorg-driver/xf86-video-imxfb-vivante_3.5.7-1.0.0-alpha.2.bb @@ -0,0 +1,59 @@ +# Copyright (C) 2012-2013 Freescale Semiconductor +# Copyright (C) 2012-2013 O.S. Systems Software LTDA. +# Released under the MIT license (see COPYING.MIT for the terms) + +require recipes-graphics/xorg-driver/xorg-driver-video.inc + +PE = "3" + +DEPENDS += "virtual/xserver virtual/libx11 virtual/libgal-x11 gpu-viv-bin-mx6q pixman" + +LIC_FILES_CHKSUM = "file://EXA/src/vivante_fbdev/vivante.h;endline=19;md5=641ac6e6d013833e36290797f4d7089c" + +SRC_URI = "${FSL_MIRROR}/xserver-xorg-video-imx-viv-${PV}.tar.gz" +SRC_URI[md5sum] = "3fc3d355d721656144920afd06fb1bff" +SRC_URI[sha256sum] = "49fab65a0a1ea74ec6b04700e035b1351244fbd363301d59d6d0cbffe37d6fb9" + +EXTRA_OEMAKE += "-C EXA/src -f makefile.linux prefix=${D}/usr \ + sysroot=${STAGING_DIR_TARGET} \ + BUSID_HAS_NUMBER=1 \ + BUILD_IN_YOCTO=1 \ + XSERVER_GREATER_THAN_13=1" + +CFLAGS += "-I${STAGING_INCDIR}/xorg \ + -I${STAGING_INCDIR}/drm \ + -I../../DRI_1.10.4/src" + +S = "${WORKDIR}/xserver-xorg-video-imx-viv-${PV}/" + +# FIXME: The Freescale provided Makefile has hardcodec include paths +# and this does not work in case prefix is different than /usr, +# sed it. +do_configure_prepend () { + sed -i 's,$(sysroot)/usr/include,${STAGING_INCDIR},g' \ + ${S}EXA/src/makefile.linux +} + +# FIXME: This is need as Freescale didn't use standard Makefile filename +# thus oe_runmame thinks nothing is need to be done, use ln to +# workaround it. +base_do_compile () { + oe_runmake || die "make failed" +} + +do_install_append () { + install -d ${D}${includedir} + cp -axr ${S}/EXA/src/vivante_gal/vivante_priv.h ${D}${includedir} + cp -axr ${S}/EXA/src/vivante_gal/vivante_gal.h ${D}${includedir} + find ${D}${includedir} -type f -exec chmod 660 {} \; +} + +RDEPENDS_${PN} += "libvivante-dri-mx6 \ + xserver-xorg-module-exa \ + mesa-driver-swrast \ + xserver-xorg-extension-dri \ + xserver-xorg-extension-dri2 \ + xserver-xorg-extension-glx" + +PACKAGE_ARCH = "${MACHINE_ARCH}" +COMPATIBLE_MACHINE = "(mx6)" -- 1.8.4.rc1 _______________________________________________ meta-freescale mailing list meta-freescale@yoctoproject.org https://lists.yoctoproject.org/listinfo/meta-freescale