summaryrefslogtreecommitdiffstats
path: root/poky/meta/recipes-graphics/xorg-lib/libx11
diff options
context:
space:
mode:
Diffstat (limited to 'poky/meta/recipes-graphics/xorg-lib/libx11')
-rw-r--r--poky/meta/recipes-graphics/xorg-lib/libx11/Fix-hanging-issue-in-_XReply.patch60
-rw-r--r--poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff520
-rw-r--r--poky/meta/recipes-graphics/xorg-lib/libx11/disable_tests.patch22
-rw-r--r--poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff17
-rw-r--r--poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch19
5 files changed, 638 insertions, 0 deletions
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/Fix-hanging-issue-in-_XReply.patch b/poky/meta/recipes-graphics/xorg-lib/libx11/Fix-hanging-issue-in-_XReply.patch
new file mode 100644
index 000000000..897882b8d
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/Fix-hanging-issue-in-_XReply.patch
@@ -0,0 +1,60 @@
+From 5235a7f3692a4c3c90dd4ac1be3c670388904bbe Mon Sep 17 00:00:00 2001
+From: Tatu Frisk <tatu.frisk@ge.com>
+Date: Tue, 14 Mar 2017 14:41:27 +0200
+Subject: [PATCH] Fix hanging issue in _XReply
+
+Assume event queue is empty if another thread is blocking waiting for event.
+
+If one thread was blocking waiting for an event and another thread sent a
+reply to the X server, both threads got blocked until an event was
+received.
+
+Upstream-Status: Submitted [https://patchwork.freedesktop.org/patch/171458/]
+
+This patch needs to be removed once the corresponding patch has been merged upstream.
+
+https://patchwork.freedesktop.org/patch/171458/
+
+Signed-off-by: Tatu Frisk <tatu.frisk@ge.com>
+Signed-off-by: Jose Alarcon <jose.alarcon@ge.com>
+---
+ src/xcb_io.c | 19 +++++++------------
+ 1 file changed, 7 insertions(+), 12 deletions(-)
+
+diff --git a/src/xcb_io.c b/src/xcb_io.c
+index 5987329..c64eb04 100644
+--- a/src/xcb_io.c
++++ b/src/xcb_io.c
+@@ -609,22 +609,17 @@ Status _XReply(Display *dpy, xReply *rep, int extra, Bool discard)
+ * letting anyone else process this sequence number, we
+ * need to process any events that should have come
+ * earlier. */
+-
+ if(dpy->xcb->event_owner == XlibOwnsEventQueue)
+ {
+ xcb_generic_reply_t *event;
+- /* If some thread is already waiting for events,
+- * it will get the first one. That thread must
+- * process that event before we can continue. */
+- /* FIXME: That event might be after this reply,
+- * and might never even come--or there might be
+- * multiple threads trying to get events. */
+- while(dpy->xcb->event_waiter)
+- { /* need braces around ConditionWait */
+- ConditionWait(dpy, dpy->xcb->event_notify);
++
++ /* Assume event queue is empty if another thread is blocking
++ * waiting for event. */
++ if(!dpy->xcb->event_waiter)
++ {
++ while((event = poll_for_response(dpy)))
++ handle_response(dpy, event, True);
+ }
+- while((event = poll_for_event(dpy)))
+- handle_response(dpy, event, True);
+ }
+
+ req->reply_waiter = 0;
+--
+2.10.1
+
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff b/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff
new file mode 100644
index 000000000..744cedc77
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff
@@ -0,0 +1,520 @@
+Upstream-Status: Pending
+
+Upstream-Status: Inappropriate [configuration]
+Index: libX11-1.3/src/imConv.c
+===================================================================
+--- libX11-1.3.orig/src/imConv.c
++++ libX11-1.3/src/imConv.c
+@@ -83,6 +83,7 @@ static const struct SubstRec SubstTable[
+ * from UCS char to specified charset char.
+ * This converter is needed for _XimGetCharCode subroutine.
+ */
++#ifdef XLOCALE
+ XPointer
+ _XimGetLocaleCode (
+ _Xconst char* encoding_name)
+@@ -96,6 +97,7 @@ _XimGetLocaleCode (
+ }
+ return cvt;
+ }
++#endif
+
+ /*
+ * Returns the locale dependent representation of a keysym.
+@@ -106,6 +108,7 @@ _XimGetLocaleCode (
+ * terminating NUL byte. Return 0 if the keysym is not representable in the
+ * locale
+ */
++#ifdef XLOCALE
+ /*ARGSUSED*/
+ int
+ _XimGetCharCode (
+@@ -135,6 +138,7 @@ _XimGetCharCode (
+ buf[count]= '\0';
+ return count;
+ }
++#endif
+
+ #ifdef XKB
+ static int lookup_string(
+Index: libX11-1.3/src/X18NCMSstubs.c
+===================================================================
+--- /dev/null
++++ libX11-1.3/src/X18NCMSstubs.c
+@@ -0,0 +1,428 @@
++/*
++ * X18NCMSstubs.c
++ * - Provides stubs and dummy funcs needed when Xcms and XLocale stuff removed
++ *
++ * Copyright © 2003 Matthew Allum
++ *
++ * Permission to use, copy, modify, distribute, and sell this software and its
++ * documentation for any purpose is hereby granted without fee, provided that
++ * the above copyright notice appear in all copies and that both that
++ * copyright notice and this permission notice appear in supporting
++ * documentation, and that the name of Matthew Allum not be used in
++ * advertising or publicity pertaining to distribution of the software without
++ * specific, written prior permission. Keith Packard and Compaq makes no
++ * representations about the suitability of this software for any purpose. It
++ * is provided "as is" without express or implied warranty.
++ *
++ * MATTHEW ALLUM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS
++ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
++ * IN NO EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
++ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
++ * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
++ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
++ * PERFORMANCE OF THIS SOFTWARE.
++ */
++
++#include <stdlib.h>
++#include "Xlibint.h"
++#include "Xlcint.h"
++#include <X11/Xlocale.h>
++#include <X11/Xos.h>
++#ifdef WIN32
++#undef close
++#endif
++#include <X11/Xutil.h>
++#include "XlcPubI.h"
++
++#include "Xcmsint.h" /* for XcmsCCC type */
++#include "XlcPubI.h" /* for XLCd type */
++#include "config.h"
++
++#if ! XLOCALE
++
++Bool
++XSupportsLocale()
++{
++ return False;
++}
++
++char *
++XSetLocaleModifiers(
++ const char *modifiers)
++{
++ return NULL;
++}
++
++XLCd
++_XOpenLC(
++ char *name)
++{
++ return NULL;
++}
++
++XLCd
++_XlcCurrentLC()
++{
++ return NULL;
++}
++
++void
++_XlcVaToArgList(
++ va_list var,
++ int count,
++ XlcArgList *args_ret)
++{
++ return;
++}
++
++void
++_XlcCountVaList(
++ va_list var,
++ int *count_ret)
++{
++ return;
++}
++
++void
++_XCloseLC(
++ XLCd lcd)
++{
++ return;
++}
++
++int
++_XlcConvert(
++ XlcConv conv,
++ XPointer *from,
++ int *from_left,
++ XPointer *to,
++ int *to_left,
++ XPointer *args,
++ int num_args)
++{
++ return 0;
++}
++
++/* XIM Stubs */
++
++XPointer
++_XimGetLocaleCode ( _Xconst char* encoding_name )
++{
++ return NULL;
++}
++
++int
++_XimGetCharCode (
++ XPointer ucs_conv,
++ KeySym keysym,
++ unsigned char* buf,
++ int nbytes)
++{
++ return 0;
++}
++
++/* Xrm Stubs */
++
++XrmMethods
++_XrmInitParseInfo(
++ XPointer *state)
++{
++ return (XrmMethods) NULL;
++}
++
++/* Xwc Stubs */
++
++int
++XwcTextExtents(
++ XFontSet font_set,
++ _Xconst wchar_t *text,
++ int text_len,
++ XRectangle *overall_ink_extents,
++ XRectangle *overall_logical_extents)
++{
++ return 0;
++}
++
++void
++XwcDrawString(Display *display,
++ Drawable d,
++ XFontSet font_set,
++ GC gc,
++ int x, int y,
++ _Xconst wchar_t *string,
++ int num_wchars)
++{
++ ;
++}
++
++void
++XwcDrawText(
++ Display *dpy,
++ Drawable d,
++ GC gc,
++ int x,
++ int y,
++ XwcTextItem *text_items,
++ int nitems)
++{
++ ;
++}
++
++void
++XwcDrawImageString(
++ Display *dpy,
++ Drawable d,
++ XFontSet font_set,
++ GC gc,
++ int x,
++ int y,
++ _Xconst wchar_t *text,
++ int text_len)
++{
++ ;
++}
++
++int
++XwcTextEscapement(
++ XFontSet font_set,
++ _Xconst wchar_t *text,
++ int text_len)
++{
++ return 0;
++}
++
++Status
++XwcTextPerCharExtents(
++ XFontSet font_set,
++ _Xconst wchar_t *text,
++ int text_len,
++ XRectangle *ink_extents_buffer,
++ XRectangle *logical_extents_buffer,
++ int buffer_size,
++ int *num_chars,
++ XRectangle *max_ink_extents,
++ XRectangle *max_logical_extents)
++{
++ return(XcmsFailure);
++}
++
++int
++XwcTextPropertyToTextList(
++ Display *dpy,
++ const XTextProperty *text_prop,
++ wchar_t ***list_ret,
++ int *count_ret)
++{
++ return 0;
++}
++
++int
++XwcTextListToTextProperty(
++ Display *dpy,
++ wchar_t **list,
++ int count,
++ XICCEncodingStyle style,
++ XTextProperty *text_prop)
++{
++ return 0;
++}
++
++void
++XwcFreeStringList(wchar_t **list)
++{
++ return;
++}
++
++
++void XmbSetWMProperties ( /* Actually from mbWMProps.c */
++ Display *dpy,
++ Window w,
++ _Xconst char *windowName,
++ _Xconst char *iconName,
++ char **argv,
++ int argc,
++ XSizeHints *sizeHints,
++ XWMHints *wmHints,
++ XClassHint *classHints)
++{
++ return;
++}
++
++int
++XmbTextPropertyToTextList(
++ Display *dpy,
++ const XTextProperty *text_prop,
++ char ***list_ret,
++ int *count_ret)
++{
++ return XLocaleNotSupported;
++}
++
++int
++XmbTextListToTextProperty(
++ Display *dpy,
++ char **list,
++ int count,
++ XICCEncodingStyle style,
++ XTextProperty *text_prop)
++{
++ return XLocaleNotSupported;
++}
++
++int
++XmbTextExtents(
++ XFontSet font_set,
++ _Xconst char *text,
++ int text_len,
++ XRectangle *overall_ink_extents,
++ XRectangle *overall_logical_extents)
++{
++ return 0;
++}
++
++void
++XmbDrawText(
++ Display *dpy,
++ Drawable d,
++ GC gc,
++ int x,
++ int y,
++ XmbTextItem *text_items,
++ int nitems)
++{
++ ;
++}
++
++void
++XmbDrawString(
++ Display *dpy,
++ Drawable d,
++ XFontSet font_set,
++ GC gc,
++ int x,
++ int y,
++ _Xconst char *text,
++ int text_len)
++{
++ ;
++}
++
++void
++XmbDrawImageString(
++ Display *dpy,
++ Drawable d,
++ XFontSet font_set,
++ GC gc,
++ int x,
++ int y,
++ _Xconst char *text,
++ int text_len)
++{
++ ;
++}
++
++int
++XmbTextEscapement(
++ XFontSet font_set,
++ _Xconst char *text,
++ int text_len)
++{
++ return 0;
++}
++
++Status
++XmbTextPerCharExtents(
++ XFontSet font_set,
++ _Xconst char *text,
++ int text_len,
++ XRectangle *ink_extents_buffer,
++ XRectangle *logical_extents_buffer,
++ int buffer_size,
++ int *num_chars,
++ XRectangle *max_ink_extents,
++ XRectangle *max_logical_extents)
++{
++ return 0;
++}
++
++unsigned int
++KeySymToUcs4(KeySym keysym)
++{
++ return 0;
++}
++
++#endif
++
++#if ! XCMS
++
++XcmsCCC
++XcmsCCCOfColormap(dpy, cmap)
++ Display *dpy;
++ Colormap cmap;
++{
++ return NULL;
++}
++
++Status
++_XcmsResolveColorString (
++ XcmsCCC ccc,
++ const char **color_string,
++ XcmsColor *pColor_exact_return,
++ XcmsColorFormat result_format)
++{
++ return(XcmsFailure);
++}
++
++void
++_XcmsUnresolveColor(
++ XcmsCCC ccc,
++ XcmsColor *pColor)
++{
++ return;
++}
++
++void
++_XUnresolveColor(
++ XcmsCCC ccc,
++ XColor *pXColor)
++{
++ return;
++}
++
++XcmsCmapRec *
++_XcmsAddCmapRec(dpy, cmap, windowID, visual)
++ Display *dpy;
++ Colormap cmap;
++ Window windowID;
++ Visual *visual;
++{
++ return NULL;
++}
++
++void
++_XcmsRGB_to_XColor(
++ XcmsColor *pColors,
++ XColor *pXColors,
++ unsigned int nColors)
++{
++ return;
++}
++
++XcmsCmapRec *
++_XcmsCopyCmapRecAndFree(
++ Display *dpy,
++ Colormap src_cmap,
++ Colormap copy_cmap)
++{
++ return NULL;
++}
++
++void
++_XcmsDeleteCmapRec(
++ Display *dpy,
++ Colormap cmap)
++{
++ return;
++}
++
++#endif
+Index: libX11-1.3/src/Makefile.am
+===================================================================
+--- libX11-1.3.orig/src/Makefile.am
++++ libX11-1.3/src/Makefile.am
+@@ -335,6 +335,8 @@ if THRSTUBS
+ libX11_la_SOURCES+=UIThrStubs.c
+ endif
+
++libX11_la_SOURCES+=X18NCMSstubs.c
++
+ x11datadir = @X11_DATADIR@
+ x11data_DATA = XKeysymDB XErrorDB
+
+@@ -342,6 +344,7 @@ EXTRA_DIST = \
+ $(x11data_DATA) \
+ os2Stubs.c \
+- UIThrStubs.c
++ UIThrStubs.c \
++ X18NCMSstubs.c
+
+ if XCB
+ libX11_la_SOURCES += \
+Index: libX11-1.3/src/locking.c
+===================================================================
+--- libX11-1.3.orig/src/locking.c
++++ libX11-1.3/src/locking.c
+@@ -66,7 +66,9 @@ in this Software without prior written a
+ #define NUM_FREE_CVLS 4
+
+ /* in lcWrap.c */
++#ifdef XLOCALE
+ extern LockInfoPtr _Xi18n_lock;
++#endif
+
+ #ifdef WIN32
+ static DWORD _X_TlsIndex = (DWORD)-1;
+@@ -594,9 +596,11 @@ Status XInitThreads(void)
+ _Xglobal_lock = &global_lock;
+ xmutex_init(_Xglobal_lock->lock);
+ xmutex_set_name(_Xglobal_lock->lock, "Xlib global");
++#ifdef XLOCALE
+ _Xi18n_lock = &i18n_lock;
+ xmutex_init(_Xi18n_lock->lock);
+ xmutex_set_name(_Xi18n_lock->lock, "Xlib i18n");
++#endif
+ _XLockMutex_fn = _XLockMutex;
+ _XUnlockMutex_fn = _XUnlockMutex;
+ _XCreateMutex_fn = _XCreateMutex;
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/disable_tests.patch b/poky/meta/recipes-graphics/xorg-lib/libx11/disable_tests.patch
new file mode 100644
index 000000000..c1b6cde53
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/disable_tests.patch
@@ -0,0 +1,22 @@
+Upstream-Status: Inappropriate [disable feature]
+
+Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
+
+Update for 1.6.1
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+diff -Nurd libX11-1.5.0/nls/Makefile.am libX11-1.5.0/nls/Makefile.am
+--- libX11-1.5.0/nls/Makefile.am 2012-06-02 09:37:18.000000000 +0300
++++ libX11-1.5.0/nls/Makefile.am 2013-01-02 16:10:24.960156131 +0200
+@@ -36,11 +36,6 @@
+ < locale.dir.l1 > locale.dir.l2
+ cat locale.dir.l2 locale.dir.l1 > locale.dir
+
+-if HAVE_PERL
+-LOG_COMPILER = $(PERL)
+-TESTS = compose-check.pl
+-endif HAVE_PERL
+-
+
+ # Per-locale data files
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff
new file mode 100644
index 000000000..a7c3984fd
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff
@@ -0,0 +1,17 @@
+Upstream-Status: Pending
+
+Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
+--- libX11-X11R7.0-1.0.0/src/Font.c.orig 2006-03-12 18:35:42.000000000 +0100
++++ libX11-X11R7.0-1.0.0/src/Font.c 2006-03-12 18:40:27.000000000 +0100
+@@ -701,7 +701,11 @@
+ }
+ if (l - 2 - (p - charset) < 0)
+ return 0;
++#ifdef XLOCALE
+ if (_XlcNCompareISOLatin1(name + l - 2 - (p - charset), charset, p - charset))
++#else
++ if (strncasecmp(name + l - 2 - (p - charset), charset, p - charset))
++#endif
+ return 0;
+ if (strlen(p + 1) + l - 1 >= sizeof(buf) - 1)
+ return 0;
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch
new file mode 100644
index 000000000..c6347f5be
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch
@@ -0,0 +1,19 @@
+Upstream-Status: Pending
+
+Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
+
+#
+# Patch managed by http://www.holgerschurig.de/patcher.html
+#
+
+--- libX11-X11R7.0-1.0.0/include/X11/Xlib.h~fix-utf8-wrong-define
++++ libX11-X11R7.0-1.0.0/include/X11/Xlib.h
+@@ -103,7 +103,7 @@
+
+ /* API mentioning "UTF8" or "utf8" is an XFree86 extension, introduced in
+ November 2000. Its presence is indicated through the following macro. */
+-#define X_HAVE_UTF8_STRING 1
++#undef X_HAVE_UTF8_STRING
+
+ typedef char *XPointer;
+
OpenPOWER on IntegriCloud