From 42a45352ddd64ac94a1ef1334cb28447cc3cbdd8 Mon Sep 17 00:00:00 2001 From: Marcel Ziswiler Date: Mon, 8 Dec 2014 02:06:27 +0100 Subject: xserver-xorg: upgrade to 1.14.7 This is an upgrade from the former 1.14.4 recipe as found here: http://cgit.openembedded.org/openembedded-core/tree/meta/ recipes-graphics/xorg-xserver?id= b8feee3cf21f70ba4ec3b822d2f596d4fc02a292 --- recipes-graphics/xorg-xserver/xserver-xorg.inc | 154 +++++++++++++++++++++ .../xorg-xserver/xserver-xorg/aarch64.patch | 35 +++++ .../xorg-xserver/xserver-xorg/crosscompile.patch | 22 +++ .../fix_open_max_preprocessor_error.patch | 15 ++ .../xorg-xserver/xserver-xorg/macro_tweak.patch | 25 ++++ .../xserver-xorg/mips64-compiler.patch | 29 ++++ .../xserver-xorg/xorg-CVE-2013-6424.patch | 31 +++++ .../xorg-xserver/xserver-xorg_1.14.7.bb | 35 +++++ 8 files changed, 346 insertions(+) create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg.inc create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg/crosscompile.patch create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg/fix_open_max_preprocessor_error.patch create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg/mips64-compiler.patch create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg/xorg-CVE-2013-6424.patch create mode 100644 recipes-graphics/xorg-xserver/xserver-xorg_1.14.7.bb (limited to 'recipes-graphics') diff --git a/recipes-graphics/xorg-xserver/xserver-xorg.inc b/recipes-graphics/xorg-xserver/xserver-xorg.inc new file mode 100644 index 0000000..2bacbe5 --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg.inc @@ -0,0 +1,154 @@ +SUMMARY = "The X.Org X server" +HOMEPAGE = "http://www.x.org" +SECTION = "x11/base" +LICENSE = "MIT-X" +LIC_FILES_CHKSUM = "file://COPYING;md5=15b5bf9327341c81089137aec4830bfd" + +# xf86-*-* packages depend on an X server built with the xfree86 DDX +# so we have a virtual to represent that: +# deprecated, we should use virtual/xserver instead +PROVIDES = "virtual/xserver-xf86" + +# Other packages tend to just care that there is *an* X server: +PROVIDES += "virtual/xserver" + +PE = "2" +INC_PR = "r8" + +XORG_PN = "xorg-server" +SRC_URI = "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${PV}.tar.bz2" +SRC_URI += "file://macro_tweak.patch" + +S = "${WORKDIR}/${XORG_PN}-${PV}" + +inherit autotools pkgconfig + +PROTO_DEPS = "randrproto renderproto fixesproto damageproto xextproto xproto xf86dgaproto xf86miscproto xf86vidmodeproto compositeproto recordproto resourceproto videoproto scrnsaverproto xineramaproto fontsproto kbproto inputproto bigreqsproto xcmiscproto presentproto" +LIB_DEPS = "pixman libxfont xtrans libxau libxext libxdmcp libdrm libxkbfile libpciaccess openssl libgcrypt" +DEPENDS = "${PROTO_DEPS} ${LIB_DEPS} font-util" + +# Split out some modules and extensions from the main package +# These aren't needed for basic operations and only take up space: +# 32.0k libdri.so +# 91.0k libexa.so +# 336.0k libglx.so +# 1360k libint10.so +# 180.0k libwfb.so +# 320.0k libxaa.so +# 124.0k libxf1bpp.so +# 84.0k libxf4bpp.so +# librecord.so +# libextmod.so +# libdbe.so + +PACKAGES =+ "${PN}-security-policy \ + ${PN}-sdl \ + ${PN}-fbdev \ + ${PN}-xvfb \ + ${PN}-utils \ + ${PN}-xephyr \ + ${PN}-multimedia-modules \ + ${PN}-extension-dri \ + ${PN}-extension-dri2 \ + ${PN}-extension-glx \ + ${PN}-extension-record \ + ${PN}-extension-extmod \ + ${PN}-extension-dbe \ + ${PN}-module-libint10 \ + ${PN}-module-libafb \ + ${PN}-module-libwfb \ + ${PN}-module-libmfb \ + ${PN}-module-libcfb \ + ${PN}-module-exa \ + ${PN}-module-xaa \ + ${PN}-module-libxf1bpp \ + ${PN}-module-libxf4bpp" + +RRECOMMENDS_${PN} += "${PN}-security-policy xkeyboard-config rgb xserver-xf86-config xkbcomp" +RDEPENDS_${PN}-xvfb += "xkeyboard-config" +RDEPENDS_${PN}-module-exa = "${PN} (= ${EXTENDPKGV})" + +FILES_${PN} = "${bindir} ${libdir}/X11/Options ${libdir}/X11/Cards ${libdir}/X11/getconfig ${libdir}/X11/etc ${libdir}/modules/*.so ${libdir}/xorg/modules/*.so /etc/X11 ${libdir}/xorg/protocol.txt ${datadir}/X11/xorg.conf.d" +FILES_${PN}-dev += "${libdir}/xorg/modules/*.la ${libdir}/xorg/modules/*/*.la" +FILES_${PN}-doc += "${libdir}/X11/doc ${datadir}/X11/xkb/compiled/README.compiled ${localstatedir}/lib/xkb/README.compiled" +FILES_${PN}-dbg += "${libdir}/xorg/modules/.debug \ + ${libdir}/xorg/modules/*/.debug \ + ${libdir}/xorg/modules/*/*/.debug \ + " +FILES_${PN}-security-policy += "${libdir}/xserver/SecurityPolicy" +FILES_${PN}-sdl = "${bindir}/Xsdl" +FILES_${PN}-fbdev = "${bindir}/Xfbdev" +FILES_${PN}-xvfb = "${bindir}/Xvfb" +FILES_${PN}-utils = "${bindir}/scanpci ${bindir}/pcitweak ${bindir}/ioport ${bindir}/in[bwl] ${bindir}/out[bwl] ${bindir}/mmap[rw] ${bindir}/gtf ${bindir}/getconfig ${bindir}/getconfig.pl" +FILES_${PN}-xephyr = "${bindir}/Xephyr" +FILES_${PN}-multimedia-modules = "${libdir}/xorg/modules/multimedia/*drv*" +FILES_${PN}-extension-dri = "${libdir}/xorg/modules/extensions/libdri.so" +FILES_${PN}-extension-dri2 = "${libdir}/xorg/modules/extensions/libdri2.so" +FILES_${PN}-extension-glx = "${libdir}/xorg/modules/extensions/libglx.so" +FILES_${PN}-extension-record = "${libdir}/xorg/modules/extensions/librecord.so" +FILES_${PN}-extension-extmod = "${libdir}/xorg/modules/extensions/libextmod.so" +FILES_${PN}-extension-dbe = "${libdir}/xorg/modules/extensions/libdbe.so" +FILES_${PN}-module-libint10 = "${libdir}/xorg/modules/libint10.so" +FILES_${PN}-module-libafb = "${libdir}/xorg/modules/libafb.so" +FILES_${PN}-module-libwfb = "${libdir}/xorg/modules/libwfb.so" +FILES_${PN}-module-libmfb = "${libdir}/xorg/modules/libmfb.so" +FILES_${PN}-module-libcfb = "${libdir}/xorg/modules/libcfb.so" +FILES_${PN}-module-exa = "${libdir}/xorg/modules/libexa.so" +FILES_${PN}-module-xaa = "${libdir}/xorg/modules/libxaa.so" +FILES_${PN}-module-libxf1bpp = "${libdir}/xorg/modules/libxf1bpp.so" +FILES_${PN}-module-libxf4bpp = "${libdir}/xorg/modules/libxf4bpp.so" + +EXTRA_OECONF += "--with-fop=no \ + --without-xmlto \ + --with-pic \ + --disable-static \ + --disable-xinerama \ + --disable-record \ + --disable-dmx \ + --disable-xnest \ + --enable-xvfb \ + --enable-composite \ + --without-dtrace \ + --with-int10=x86emu \ + --sysconfdir=/etc/X11 \ + --localstatedir=/var \ + --with-xkb-output=/var/lib/xkb \ + ac_cv_file__usr_share_sgml_X11_defs_ent=no \ +" + +PACKAGECONFIG ??= "udev ${@base_contains('DISTRO_FEATURES', 'opengl', 'dri dri2 glx', '', d)}" +PACKAGECONFIG[udev] = "--enable-config-udev,--disable-config-udev,udev" +PACKAGECONFIG[dri] = "--enable-dri,--disable-dri,glproto virtual/mesa xf86driproto" +PACKAGECONFIG[dri2] = "--enable-dri2,--disable-dri2,dri2proto" +PACKAGECONFIG[glx] = "--enable-glx --enable-glx-tls,--disable-glx,glproto virtual/libgl virtual/libx11" + +do_install_append () { + # Its assumed base-files creates this for us + rmdir ${D}${localstatedir}/log/ +} + +# Add runtime provides for the ABI versions of the video and input subsystems, +# so that drivers can depend on the relevant version. +python populate_packages_prepend() { + import subprocess + + # Set PKG_CONFIG_PATH so pkg-config looks at the .pc files that are going + # into the new package, not the staged ones. + newenv = dict(os.environ) + newenv["PKG_CONFIG_PATH"] = d.expand("${PKGD}${libdir}/pkgconfig/") + + def get_abi(name): + abis = { + "video": "abi_videodrv", + "input": "abi_xinput" + } + p = subprocess.Popen(args="pkg-config --variable=%s xorg-server" % abis[name], + shell=True, env=newenv, stdout=subprocess.PIPE) + output = p.communicate()[0] + mlprefix = d.getVar('MLPREFIX', True) or '' + return "%sxorg-abi-%s-%s" % (mlprefix, name, output.split(".")[0]) + + pn = d.getVar("PN", True) + d.appendVar("RPROVIDES_" + pn, " " + get_abi("input")) + d.appendVar("RPROVIDES_" + pn, " " + get_abi("video")) +} diff --git a/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch b/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch new file mode 100644 index 0000000..045e24a --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch @@ -0,0 +1,35 @@ +Subject: Add AArch64 support to xserver-xorg +Author: Marcin Juszkiewicz + +lnx_video.c parts are not existing in 1.14 branch. + +Xserver was checked in AArch64 fastmodel (commercial one with graphics support). + +http://patchwork.freedesktop.org/patch/12785/ + +Upstream-Status: Pending + +--- + include/servermd.h | 7 +++++++ + 1 files changed, 7 insertions(+), 0 deletions(-) + +--- xorg-server-1.13.1.orig/include/servermd.h ++++ xorg-server-1.13.1/include/servermd.h +@@ -243,10 +243,17 @@ SOFTWARE. + #define BITMAP_BIT_ORDER LSBFirst + #define GLYPHPADBYTES 4 + /* ???? */ + #endif /* AMD64 */ + ++#if defined(__aarch64__) || defined(aarch64) || defined(__aarch64) ++#define IMAGE_BYTE_ORDER MSBFirst ++#define BITMAP_BIT_ORDER MSBFirst ++#define GLYPHPADBYTES 4 ++/* ???? */ ++#endif /* AArch64 */ ++ + #if defined(SVR4) && (defined(__i386__) || defined(__i386) ) || \ + defined(__alpha__) || defined(__alpha) || \ + defined(__i386__) || \ + defined(__s390x__) || defined(__s390__) + diff --git a/recipes-graphics/xorg-xserver/xserver-xorg/crosscompile.patch b/recipes-graphics/xorg-xserver/xserver-xorg/crosscompile.patch new file mode 100644 index 0000000..2f98bb8 --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg/crosscompile.patch @@ -0,0 +1,22 @@ +Upstream-Status: Inappropriate [configuration] + +diff --git a/configure.ac b/configure.ac +index b3b752c..600500b 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -523,13 +523,9 @@ dnl Uses --default-font-path if set, otherwise checks for /etc/X11/fontpath.d, + dnl otherwise uses standard subdirectories of FONTROOTDIR. When cross + dnl compiling, assume default font path uses standard FONTROOTDIR directories. + DEFAULT_FONT_PATH="${FONTMISCDIR}/,${FONTTTFDIR}/,${FONTOTFDIR}/,${FONTTYPE1DIR}/,${FONT100DPIDIR}/,${FONT75DPIDIR}/" +-if test "$cross_compiling" != yes; then +- AC_CHECK_FILE([${sysconfdir}/X11/fontpath.d], +- [DEFAULT_FONT_PATH='catalogue:${sysconfdir}/X11/fontpath.d'], +- [case $host_os in ++ case $host_os in + darwin*) DEFAULT_FONT_PATH="${DEFAULT_FONT_PATH},/Library/Fonts,/System/Library/Fonts" ;; +- esac]) +-fi ++ esac + AC_ARG_WITH(default-font-path, AS_HELP_STRING([--with-default-font-path=PATH], [Comma separated list of font dirs]), + [ FONTPATH="$withval" ], + [ FONTPATH="${DEFAULT_FONT_PATH}" ]) diff --git a/recipes-graphics/xorg-xserver/xserver-xorg/fix_open_max_preprocessor_error.patch b/recipes-graphics/xorg-xserver/xserver-xorg/fix_open_max_preprocessor_error.patch new file mode 100644 index 0000000..2f62972 --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg/fix_open_max_preprocessor_error.patch @@ -0,0 +1,15 @@ +Upstream-Status: Pending + +Index: git/os/osdep.h +=================================================================== +--- git.orig/os/osdep.h 2008-10-07 18:38:21.000000000 +0100 ++++ git/os/osdep.h 2008-10-07 18:39:36.000000000 +0100 +@@ -92,7 +92,7 @@ + * like sysconf(_SC_OPEN_MAX) is not supported. + */ + +-#if OPEN_MAX <= 256 ++#if 0 + #define MAXSOCKS (OPEN_MAX - 1) + #else + #define MAXSOCKS 256 diff --git a/recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch b/recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch new file mode 100644 index 0000000..ec0eea6 --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch @@ -0,0 +1,25 @@ +This is the revised version of files/macro_tweak.patch for +xorg-server 1.8.99.904 and newer. + +Upstream-Status: Pending + +Signed-off-by: Yu Ke + +diff --git a/xorg-server.m4 b/xorg-server.m4 +index bdecf62..040fdb8 100644 +--- a/xorg-server.m4 ++++ b/xorg-server.m4 +@@ -28,10 +28,12 @@ dnl + # Checks for the $1 define in xorg-server.h (from the sdk). If it + # is defined, then add $1 to $REQUIRED_MODULES. + ++m4_pattern_allow(PKG_CONFIG_SYSROOT_DIR) ++ + AC_DEFUN([XORG_DRIVER_CHECK_EXT],[ + AC_REQUIRE([PKG_PROG_PKG_CONFIG]) + SAVE_CFLAGS="$CFLAGS" +- CFLAGS="$CFLAGS -I`$PKG_CONFIG --variable=sdkdir xorg-server`" ++ CFLAGS="$CFLAGS -I$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=sdkdir xorg-server`" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #include "xorg-server.h" + #if !defined $1 diff --git a/recipes-graphics/xorg-xserver/xserver-xorg/mips64-compiler.patch b/recipes-graphics/xorg-xserver/xserver-xorg/mips64-compiler.patch new file mode 100644 index 0000000..168368e --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg/mips64-compiler.patch @@ -0,0 +1,29 @@ +on mips64/n64 pointers are 64bit therefore the pointer conversions to int dont work well +so we end up with incompatible conversion errors + +This patch choses the right values for mips64 + +Signed-off-by: Khem Raj + +Upstream-Status: Pending +Index: xorg-server-1.13.0/hw/xfree86/common/compiler.h +=================================================================== +--- xorg-server-1.13.0-orig/hw/xfree86/common/compiler.h 2012-06-14 23:04:29.000000000 +0300 ++++ xorg-server-1.13.0/hw/xfree86/common/compiler.h 2012-11-08 10:06:50.865831783 +0200 +@@ -101,6 +101,7 @@ + #if defined(NO_INLINE) || defined(DO_PROTOTYPES) + #if !defined(__arm__) + #if !defined(__sparc__) && !defined(__sparc) && !defined(__arm32__) && !defined(__nds32__) \ ++ && !defined(__mips64) \ + && !(defined(__alpha__) && defined(linux)) \ + && !(defined(__ia64__) && defined(linux)) \ + +@@ -721,7 +722,7 @@ + } + + #elif defined(__mips__) || (defined(__arm32__) && !defined(__linux__)) +-#ifdef __arm32__ ++#if defined (__arm32__) || defined (__mips64) + #define PORT_SIZE long + #else + #define PORT_SIZE short diff --git a/recipes-graphics/xorg-xserver/xserver-xorg/xorg-CVE-2013-6424.patch b/recipes-graphics/xorg-xserver/xserver-xorg/xorg-CVE-2013-6424.patch new file mode 100644 index 0000000..7c61530 --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg/xorg-CVE-2013-6424.patch @@ -0,0 +1,31 @@ +This patch comes from: +http://lists.x.org/archives/xorg-devel/2013-October/037996.html + +Upstream-Status: Backport + +Signed-off-by: Baogen shang +diff -Naur xorg-server-1.14.0-orig/exa/exa_render.c xorg-server-1.14.0/exa/exa_render.c +--- xorg-server-1.14.0-orig/exa/exa_render.c 2014-02-27 14:32:38.000000000 +0800 ++++ xorg-server-1.14.0/exa/exa_render.c 2014-02-27 15:46:59.000000000 +0800 +@@ -1141,7 +1141,8 @@ + + exaPrepareAccess(pPicture->pDrawable, EXA_PREPARE_DEST); + for (; ntrap; ntrap--, traps++) +- (*ps->RasterizeTrapezoid) (pPicture, traps, -bounds.x1, -bounds.y1); ++ if (xTrapezoidValid(traps)) ++ (*ps->RasterizeTrapezoid) (pPicture, traps, -bounds.x1, -bounds.y1); + exaFinishAccess(pPicture->pDrawable, EXA_PREPARE_DEST); + + xRel = bounds.x1 + xSrc - xDst; +diff -Naur xorg-server-1.14.0-orig/render/picture.h xorg-server-1.14.0/render/picture.h +--- xorg-server-1.14.0-orig/render/picture.h 2014-02-27 14:32:26.000000000 +0800 ++++ xorg-server-1.14.0/render/picture.h 2014-02-27 15:48:13.000000000 +0800 +@@ -211,7 +211,7 @@ + /* whether 't' is a well defined not obviously empty trapezoid */ + #define xTrapezoidValid(t) ((t)->left.p1.y != (t)->left.p2.y && \ + (t)->right.p1.y != (t)->right.p2.y && \ +- (int) ((t)->bottom - (t)->top) > 0) ++ ((t)->bottom > (t)->top)) + + /* + * Standard NTSC luminance conversions: diff --git a/recipes-graphics/xorg-xserver/xserver-xorg_1.14.7.bb b/recipes-graphics/xorg-xserver/xserver-xorg_1.14.7.bb new file mode 100644 index 0000000..742ca59 --- /dev/null +++ b/recipes-graphics/xorg-xserver/xserver-xorg_1.14.7.bb @@ -0,0 +1,35 @@ +require xserver-xorg.inc + +LIC_FILES_CHKSUM = "file://COPYING;md5=bc098b9774ed096943f6c37b5beeef13" + +# Misc build failure for master HEAD +SRC_URI += "file://crosscompile.patch \ + file://fix_open_max_preprocessor_error.patch \ + file://mips64-compiler.patch \ + file://aarch64.patch \ + " + +SRC_URI[md5sum] = "0c285a813a6c3291c88d5a2b710aecb1" +SRC_URI[sha256sum] = "fcf66fa6ad86227613d2d3e8ae13ded297e2a1e947e9060a083eaf80d323451f" + +# These extensions are now integrated into the server, so declare the migration +# path for in-place upgrades. + +RREPLACES_${PN} = "${PN}-extension-dri \ + ${PN}-extension-dri2 \ + ${PN}-extension-record \ + ${PN}-extension-extmod \ + ${PN}-extension-dbe \ + " +RPROVIDES_${PN} = "${PN}-extension-dri \ + ${PN}-extension-dri2 \ + ${PN}-extension-record \ + ${PN}-extension-extmod \ + ${PN}-extension-dbe \ + " +RCONFLICTS_${PN} = "${PN}-extension-dri \ + ${PN}-extension-dri2 \ + ${PN}-extension-record \ + ${PN}-extension-extmod \ + ${PN}-extension-dbe \ + " -- cgit v1.2.3