diff options
author | Mihai Lindner <mihai.lindner@nxp.com> | 2019-12-16 15:18:37 +0200 |
---|---|---|
committer | Otavio Salvador <otavio@ossystems.com.br> | 2019-12-16 14:06:39 -0300 |
commit | 708cf0744cd073f6964cb5f3684ea45d30701c2c (patch) | |
tree | 33eb1ee63b62636f9dfa857389b2380ea6b3fd21 /recipes-graphics | |
parent | a4fdb4074644bda09b46490163886065b4c00aab (diff) | |
download | meta-freescale-708cf0744cd073f6964cb5f3684ea45d30701c2c.tar.gz |
libdrm: Upgrade to 2.4.99.imx
Refresh recipe base from poky, drops patches no longer used.
Signed-off-by: Mihai Lindner <mihai.lindner@nxp.com>
Diffstat (limited to 'recipes-graphics')
-rw-r--r-- | recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch | 54 | ||||
-rw-r--r-- | recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch | 24 | ||||
-rw-r--r-- | recipes-graphics/drm/libdrm/imxgpu2d/drm-update-arm.patch | 35 | ||||
-rw-r--r-- | recipes-graphics/drm/libdrm/installtests.patch | 25 | ||||
-rw-r--r-- | recipes-graphics/drm/libdrm/musl-ioctl.patch | 35 | ||||
-rw-r--r-- | recipes-graphics/drm/libdrm_%.bbappend | 5 | ||||
-rw-r--r-- | recipes-graphics/drm/libdrm_2.4.99.imx.bb (renamed from recipes-graphics/drm/libdrm_2.4.91.imx.bb) | 49 |
7 files changed, 62 insertions, 165 deletions
diff --git a/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch b/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch deleted file mode 100644 index fa7b218e..00000000 --- a/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch +++ /dev/null | |||
@@ -1,54 +0,0 @@ | |||
1 | From 9be904a70e6b7e6b3cc4e1b270bca02d14a4179b Mon Sep 17 00:00:00 2001 | ||
2 | From: Jussi Kukkonen <jussi.kukkonen@intel.com> | ||
3 | Date: Mon, 5 Sep 2016 14:41:37 +0300 | ||
4 | Subject: [PATCH] configure.ac: Allow explicit enabling of cunit tests | ||
5 | |||
6 | Add --with-cunit to make it easier to do reproducible builds. Default | ||
7 | is still to probe cunit and build opportunistically. | ||
8 | |||
9 | Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com> | ||
10 | Upstream-Status: Submitted [mailing list] | ||
11 | |||
12 | --- | ||
13 | configure.ac | 14 ++++++++++++-- | ||
14 | 1 file changed, 12 insertions(+), 2 deletions(-) | ||
15 | |||
16 | diff --git a/configure.ac b/configure.ac | ||
17 | index 1341f51..bef46e0 100644 | ||
18 | --- a/configure.ac | ||
19 | +++ b/configure.ac | ||
20 | @@ -168,6 +168,12 @@ AC_ARG_ENABLE(install-test-programs, | ||
21 | [Install test programs (default: no)]), | ||
22 | [INSTALL_TESTS=$enableval], [INSTALL_TESTS=no]) | ||
23 | |||
24 | +AC_ARG_WITH([cunit], | ||
25 | + [AS_HELP_STRING([--with-cunit], | ||
26 | + [Build tests that use cunit (default: auto)])], | ||
27 | + [], | ||
28 | + [with_cunit=auto]) | ||
29 | + | ||
30 | dnl =========================================================================== | ||
31 | dnl check compiler flags | ||
32 | AC_DEFUN([LIBDRM_CC_TRY_FLAG], [ | ||
33 | @@ -416,7 +422,7 @@ else | ||
34 | AC_DEFINE(HAVE_RADEON, 0) | ||
35 | fi | ||
36 | |||
37 | -if test "x$AMDGPU" != xno; then | ||
38 | +if test "x$with_cunit" != xno -a "x$AMDGPU" != xno; then | ||
39 | # Detect cunit library | ||
40 | PKG_CHECK_MODULES([CUNIT], [cunit >= 2.1], [have_cunit=yes], [have_cunit=no]) | ||
41 | # If pkg-config does not find cunit, check it using AC_CHECK_LIB. We | ||
42 | @@ -441,7 +447,11 @@ if test "x$AMDGPU" = xyes; then | ||
43 | AC_DEFINE(HAVE_AMDGPU, 1, [Have amdgpu support]) | ||
44 | |||
45 | if test "x$have_cunit" = "xno"; then | ||
46 | - AC_MSG_WARN([Could not find cunit library. Disabling amdgpu tests]) | ||
47 | + if test "x$with_cunit" = "xyes"; then | ||
48 | + AC_MSG_ERROR([Could not find cunit library but --with-cunit was given]) | ||
49 | + elif test "x$with_cunit" = "xauto"; then | ||
50 | + AC_MSG_WARN([Could not find cunit library. Disabling amdgpu tests]) | ||
51 | + fi | ||
52 | fi | ||
53 | else | ||
54 | AC_DEFINE(HAVE_AMDGPU, 0) | ||
diff --git a/recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch b/recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch deleted file mode 100644 index 4708bf1e..00000000 --- a/recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch +++ /dev/null | |||
@@ -1,24 +0,0 @@ | |||
1 | drmdevice.c: define _GNU_SOURCE | ||
2 | |||
3 | Include config.h to fix this build error with uclibc: | ||
4 | |||
5 | libdrm-2.4.66/tests/drmdevice.c: In function 'main': | ||
6 | libdrm-2.4.66/tests/drmdevice.c:96:60: error: | ||
7 | 'O_CLOEXEC' undeclared (first use in this function) | ||
8 | fd = open(devices[i]->nodes[j],O_RDONLY | O_CLOEXEC, 0); | ||
9 | |||
10 | Upstream-Status: Pending | ||
11 | |||
12 | Signed-off-by: Maxin B. John <maxin.john@intel.com> | ||
13 | --- | ||
14 | diff -Naur libdrm-2.4.66-orig/tests/drmdevice.c libdrm-2.4.66/tests/drmdevice.c | ||
15 | --- libdrm-2.4.66-orig/tests/drmdevice.c 2016-02-23 11:34:02.054904502 +0200 | ||
16 | +++ libdrm-2.4.66/tests/drmdevice.c 2016-02-23 11:35:34.371750383 +0200 | ||
17 | @@ -21,6 +21,7 @@ | ||
18 | * | ||
19 | */ | ||
20 | |||
21 | +#include <config.h> | ||
22 | #include <errno.h> | ||
23 | #include <stdio.h> | ||
24 | #include <stdlib.h> | ||
diff --git a/recipes-graphics/drm/libdrm/imxgpu2d/drm-update-arm.patch b/recipes-graphics/drm/libdrm/imxgpu2d/drm-update-arm.patch deleted file mode 100644 index 1160cd10..00000000 --- a/recipes-graphics/drm/libdrm/imxgpu2d/drm-update-arm.patch +++ /dev/null | |||
@@ -1,35 +0,0 @@ | |||
1 | Add ARM support into xf86arm.h. This provides support for Xorg interface. | ||
2 | Without this the vivante samples will hang during close requiring a reboot | ||
3 | |||
4 | Upstream-Status: Pending | ||
5 | |||
6 | Signed-off-by: Lauren Post <lauren.post@freescale.com> | ||
7 | Signed-off-by: Evan Kotara <evan.kotara@freescale.com> | ||
8 | |||
9 | diff --git a/xf86drm.h b/xf86drm.h | ||
10 | --- a/xf86drm.h | ||
11 | +++ b/xf86drm.h | ||
12 | @@ -461,6 +461,23 @@ do { register unsigned int __old __asm(" | ||
13 | : "cr0", "memory"); \ | ||
14 | } while (0) | ||
15 | |||
16 | +#elif defined(__arm__) | ||
17 | + #undef DRM_DEV_MODE | ||
18 | + #define DRM_DEV_MODE (S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH) | ||
19 | + | ||
20 | + #define DRM_CAS(lock,old,new,__ret) \ | ||
21 | + do { \ | ||
22 | + __asm__ __volatile__ ( \ | ||
23 | + "1: ldrex %0, [%1]\n" \ | ||
24 | + " teq %0, %2\n" \ | ||
25 | + " ite eq\n" \ | ||
26 | + " strexeq %0, %3, [%1]\n" \ | ||
27 | + " movne %0, #1\n" \ | ||
28 | + : "=&r" (__ret) \ | ||
29 | + : "r" (lock), "r" (old), "r" (new) \ | ||
30 | + : "cc","memory"); \ | ||
31 | + } while (0) | ||
32 | + | ||
33 | #endif /* architecture */ | ||
34 | #endif /* __GNUC__ >= 2 */ | ||
35 | |||
diff --git a/recipes-graphics/drm/libdrm/installtests.patch b/recipes-graphics/drm/libdrm/installtests.patch deleted file mode 100644 index ec1fb023..00000000 --- a/recipes-graphics/drm/libdrm/installtests.patch +++ /dev/null | |||
@@ -1,25 +0,0 @@ | |||
1 | From 5c6eb43c2f6e7f2ee7c25c92e42f4e4403fa0527 Mon Sep 17 00:00:00 2001 | ||
2 | From: Jussi Kukkonen <jussi.kukkonen@intel.com> | ||
3 | Date: Tue, 21 Feb 2017 14:37:52 +0200 | ||
4 | Subject: [PATCH] tests: also install test apps | ||
5 | |||
6 | Upstream-Status: Inappropriate [configuration] | ||
7 | |||
8 | Signed-off-by: Yu Ke <ke.yu@intel.com> | ||
9 | Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com> | ||
10 | --- | ||
11 | tests/Makefile.am | 1 + | ||
12 | 1 file changed, 1 insertion(+) | ||
13 | |||
14 | diff --git a/tests/Makefile.am b/tests/Makefile.am | ||
15 | index 0355a92..b4882cd 100644 | ||
16 | --- a/tests/Makefile.am | ||
17 | +++ b/tests/Makefile.am | ||
18 | @@ -45,3 +45,4 @@ TESTS = \ | ||
19 | check_PROGRAMS = \ | ||
20 | $(TESTS) \ | ||
21 | drmdevice | ||
22 | +bin_PROGRAMS = $(check_PROGRAMS) | ||
23 | -- | ||
24 | 2.1.4 | ||
25 | |||
diff --git a/recipes-graphics/drm/libdrm/musl-ioctl.patch b/recipes-graphics/drm/libdrm/musl-ioctl.patch new file mode 100644 index 00000000..e3d6c5b8 --- /dev/null +++ b/recipes-graphics/drm/libdrm/musl-ioctl.patch | |||
@@ -0,0 +1,35 @@ | |||
1 | Upstream-Status: Submitted | ||
2 | Signed-off-by: Ross Burton <ross.burton@intel.com> | ||
3 | |||
4 | From 46c0fd6c827a8cb4d04e067bf04fab579ac4712e Mon Sep 17 00:00:00 2001 | ||
5 | From: Ross Burton <ross.burton@intel.com> | ||
6 | Date: Mon, 18 Jun 2018 15:07:03 +0100 | ||
7 | Subject: [PATCH] tests/nouveau/threaded: adapt ioctl signature | ||
8 | |||
9 | POSIX says ioctl() has the signature (int, int, ...) but glibc has decided to | ||
10 | use (int, unsigned long int, ...) instead. | ||
11 | |||
12 | Use a #ifdef to adapt the replacement function as appropriate. | ||
13 | --- | ||
14 | tests/nouveau/threaded.c | 4 ++++ | ||
15 | 1 file changed, 4 insertions(+) | ||
16 | |||
17 | diff --git a/tests/nouveau/threaded.c b/tests/nouveau/threaded.c | ||
18 | index 3669bcd3..e1c27c01 100644 | ||
19 | --- a/tests/nouveau/threaded.c | ||
20 | +++ b/tests/nouveau/threaded.c | ||
21 | @@ -36,7 +36,11 @@ static int failed; | ||
22 | |||
23 | static int import_fd; | ||
24 | |||
25 | +#ifdef __GLIBC__ | ||
26 | int ioctl(int fd, unsigned long request, ...) | ||
27 | +#else | ||
28 | +int ioctl(int fd, int request, ...) | ||
29 | +#endif | ||
30 | { | ||
31 | va_list va; | ||
32 | int ret; | ||
33 | -- | ||
34 | 2.11.0 | ||
35 | |||
diff --git a/recipes-graphics/drm/libdrm_%.bbappend b/recipes-graphics/drm/libdrm_%.bbappend deleted file mode 100644 index 97b6df92..00000000 --- a/recipes-graphics/drm/libdrm_%.bbappend +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" | ||
2 | |||
3 | SRC_URI_append_imxgpu2d = " file://drm-update-arm.patch" | ||
4 | |||
5 | PACKAGE_ARCH_imxgpu2d = "${MACHINE_SOCARCH}" | ||
diff --git a/recipes-graphics/drm/libdrm_2.4.91.imx.bb b/recipes-graphics/drm/libdrm_2.4.99.imx.bb index 0a2d41a3..fb0d235b 100644 --- a/recipes-graphics/drm/libdrm_2.4.91.imx.bb +++ b/recipes-graphics/drm/libdrm_2.4.99.imx.bb | |||
@@ -8,31 +8,38 @@ SECTION = "x11/base" | |||
8 | LICENSE = "MIT" | 8 | LICENSE = "MIT" |
9 | LIC_FILES_CHKSUM = "file://xf86drm.c;beginline=9;endline=32;md5=c8a3b961af7667c530816761e949dc71" | 9 | LIC_FILES_CHKSUM = "file://xf86drm.c;beginline=9;endline=32;md5=c8a3b961af7667c530816761e949dc71" |
10 | PROVIDES = "drm" | 10 | PROVIDES = "drm" |
11 | DEPENDS = "libpthread-stubs libpciaccess" | 11 | DEPENDS = "libpthread-stubs" |
12 | 12 | ||
13 | IMX_LIBDRM_SRC ?= "git://source.codeaurora.org/external/imx/libdrm-imx.git;protocol=https;nobranch=1" | 13 | IMX_LIBDRM_SRC ?= "git://source.codeaurora.org/external/imx/libdrm-imx.git;protocol=https;nobranch=1" |
14 | IMX_LIBDRM_BRANCH = "libdrm-imx-2.4.91" | 14 | IMX_LIBDRM_BRANCH ?= "libdrm-imx-2.4.99" |
15 | SRC_URI = "${IMX_LIBDRM_SRC};branch=${IMX_LIBDRM_BRANCH} \ | 15 | SRC_URI = "${IMX_LIBDRM_SRC};branch=${IMX_LIBDRM_BRANCH} \ |
16 | file://installtests.patch \ | 16 | file://musl-ioctl.patch" |
17 | file://fix_O_CLOEXEC_undeclared.patch \ | 17 | SRCREV = "5748c8ff40f1ae87487c01e580f145a43542cbda" |
18 | file://0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch \ | ||
19 | " | ||
20 | SRC_URI_remove = "file://drm-update-arm.patch" | ||
21 | SRCREV = "95645843f59495387a072d48374718f22e69d7a4" | ||
22 | S = "${WORKDIR}/git" | 18 | S = "${WORKDIR}/git" |
23 | 19 | ||
24 | DEFAULT_PREFERENCE = "-1" | 20 | DEFAULT_PREFERENCE = "-1" |
25 | 21 | ||
26 | inherit autotools pkgconfig manpages | 22 | inherit meson pkgconfig manpages |
27 | 23 | ||
28 | EXTRA_OECONF += "--disable-cairo-tests \ | 24 | PACKAGECONFIG ??= "libkms intel radeon amdgpu nouveau vmwgfx omap freedreno vc4 etnaviv install-test-programs" |
29 | --without-cunit \ | 25 | PACKAGECONFIG[libkms] = "-Dlibkms=true,-Dlibkms=false" |
30 | --enable-omap-experimental-api \ | 26 | PACKAGECONFIG[intel] = "-Dintel=true,-Dintel=false,libpciaccess" |
31 | --enable-etnaviv-experimental-api \ | 27 | PACKAGECONFIG[radeon] = "-Dradeon=true,-Dradeon=false" |
32 | --enable-install-test-programs \ | 28 | PACKAGECONFIG[amdgpu] = "-Damdgpu=true,-Damdgpu=false" |
33 | --disable-valgrind \ | 29 | PACKAGECONFIG[nouveau] = "-Dnouveau=true,-Dnouveau=false" |
34 | " | 30 | PACKAGECONFIG[vmwgfx] = "-Dvmwgfx=true,-Dvmwgfx=false" |
35 | PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native" | 31 | PACKAGECONFIG[omap] = "-Domap=true,-Domap=false" |
32 | PACKAGECONFIG[exynos] = "-Dexynos=true,-Dexynos=false" | ||
33 | PACKAGECONFIG[freedreno] = "-Dfreedreno=true,-Dfreedreno=false" | ||
34 | PACKAGECONFIG[tegra] = "-Dtegra=true,-Dtegra=false" | ||
35 | PACKAGECONFIG[vc4] = "-Dvc4=true,-Dvc4=false" | ||
36 | PACKAGECONFIG[etnaviv] = "-Detnaviv=true,-Detnaviv=false" | ||
37 | PACKAGECONFIG[freedreno-kgsl] = "-Dfreedreno-kgsl=true,-Dfreedreno-kgsl=false" | ||
38 | PACKAGECONFIG[valgrind] = "-Dvalgrind=true,-Dvalgrind=false,valgrind" | ||
39 | PACKAGECONFIG[install-test-programs] = "-Dinstall-test-programs=true,-Dinstall-test-programs=false" | ||
40 | PACKAGECONFIG[cairo-tests] = "-Dcairo-tests=true,-Dcairo-tests=false" | ||
41 | PACKAGECONFIG[udev] = "-Dudev=true,-Dudev=false,udev" | ||
42 | PACKAGECONFIG[manpages] = "-Dman-pages=true,-Dman-pages=false,libxslt-native xmlto-native" | ||
36 | 43 | ||
37 | ALLOW_EMPTY_${PN}-drivers = "1" | 44 | ALLOW_EMPTY_${PN}-drivers = "1" |
38 | PACKAGES =+ "${PN}-tests ${PN}-drivers ${PN}-radeon ${PN}-nouveau ${PN}-omap \ | 45 | PACKAGES =+ "${PN}-tests ${PN}-drivers ${PN}-radeon ${PN}-nouveau ${PN}-omap \ |
@@ -51,15 +58,13 @@ FILES_${PN}-intel = "${libdir}/libdrm_intel.so.*" | |||
51 | FILES_${PN}-exynos = "${libdir}/libdrm_exynos.so.*" | 58 | FILES_${PN}-exynos = "${libdir}/libdrm_exynos.so.*" |
52 | FILES_${PN}-kms = "${libdir}/libkms*.so.*" | 59 | FILES_${PN}-kms = "${libdir}/libkms*.so.*" |
53 | FILES_${PN}-freedreno = "${libdir}/libdrm_freedreno.so.*" | 60 | FILES_${PN}-freedreno = "${libdir}/libdrm_freedreno.so.*" |
54 | FILES_${PN}-amdgpu = "${libdir}/libdrm_amdgpu.so.*" | 61 | FILES_${PN}-amdgpu = "${libdir}/libdrm_amdgpu.so.* ${datadir}/${PN}/amdgpu.ids" |
55 | FILES_${PN}-etnaviv = "${libdir}/libdrm_etnaviv.so.*" | 62 | FILES_${PN}-etnaviv = "${libdir}/libdrm_etnaviv.so.*" |
56 | 63 | ||
57 | EXTRA_OECONF_append_imxgpu = " --enable-vivante-experimental-api" | 64 | BBCLASSEXTEND = "native nativesdk" |
58 | |||
59 | PACKAGES_prepend_imxgpu = "${PN}-vivante " | ||
60 | 65 | ||
66 | PACKAGES_append_imxgpu = " ${PN}-vivante" | ||
61 | RRECOMMENDS_${PN}-drivers_append_imxgpu = " ${PN}-vivante" | 67 | RRECOMMENDS_${PN}-drivers_append_imxgpu = " ${PN}-vivante" |
62 | |||
63 | FILES_${PN}-vivante = "${libdir}/libdrm_vivante.so.*" | 68 | FILES_${PN}-vivante = "${libdir}/libdrm_vivante.so.*" |
64 | 69 | ||
65 | PACKAGE_ARCH = "${MACHINE_SOCARCH}" | 70 | PACKAGE_ARCH = "${MACHINE_SOCARCH}" |