summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--metadata/md5-cache/sys-kernel/dracut-056-r102
-rw-r--r--metadata/md5-cache/x11-libs/libX11-1.8.1-r1016
-rw-r--r--metadata/pkg_desc_index1
-rw-r--r--x11-libs/libX11/Manifest1
-rw-r--r--x11-libs/libX11/files/150.patch175
-rw-r--r--x11-libs/libX11/libX11-1.8.1-r10.ebuild46
6 files changed, 240 insertions, 1 deletions
diff --git a/metadata/md5-cache/sys-kernel/dracut-056-r10 b/metadata/md5-cache/sys-kernel/dracut-056-r10
index 76781644..095d3821 100644
--- a/metadata/md5-cache/sys-kernel/dracut-056-r10
+++ b/metadata/md5-cache/sys-kernel/dracut-056-r10
@@ -13,4 +13,4 @@ RESTRICT=!test? ( test )
SLOT=0
SRC_URI=https://www.kernel.org/pub/linux/utils/boot/dracut/dracut-056.tar.xz
_eclasses_=bash-completion-r1 f5e7a020fd9c741740756aac61bf75ff linux-info bbfa385d6907d7948d49a5e107bd654d multilib 5ca4e49abed8e3a2f7b56920eadee157 optfeature 1a2157392a869265b2afcb63a26c12ac systemd 2736b403a83f194b59b767f3b344c2c1 toolchain-funcs 1542e649be915f43f6908a9e93909961
-_md5_=8a069d9d9fa424173ae1d4f86d132713
+_md5_=97c0abb2532057658a6b5260aae40ac3
diff --git a/metadata/md5-cache/x11-libs/libX11-1.8.1-r10 b/metadata/md5-cache/x11-libs/libX11-1.8.1-r10
new file mode 100644
index 00000000..dcb15469
--- /dev/null
+++ b/metadata/md5-cache/x11-libs/libX11-1.8.1-r10
@@ -0,0 +1,16 @@
+BDEPEND=test? ( dev-lang/perl ) sys-devel/gnuconfig >=app-portage/elt-patches-20170815 || ( >=sys-devel/automake-1.16.5:1.16 ) >=sys-devel/autoconf-2.71 >=sys-devel/libtool-2.4 x86-winnt? ( >=sys-devel/libtool-2.2.6a sys-devel/m4 >=x11-misc/util-macros-1.18 >=media-fonts/font-util-1.2.0 ) virtual/pkgconfig doc? ( doc? ( || ( app-text/asciidoc dev-ruby/asciidoctor ) app-text/xmlto app-text/docbook-xml-dtd:4.1.2 app-text/docbook-xml-dtd:4.2 app-text/docbook-xml-dtd:4.3 ) )
+DEFINED_PHASES=compile configure install postinst postrm prepare test unpack
+DEPEND=>=x11-libs/libxcb-1.11.1[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,abi_mips_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_s390_32(-)?,abi_s390_64(-)?] x11-misc/compose-tables !<xfce-base/xfce4-settings-4.16.3 x11-base/xorg-proto x11-libs/xtrans
+DESCRIPTION=X.Org X11 library
+EAPI=7
+HOMEPAGE=https://www.x.org/wiki/ https://gitlab.freedesktop.org/xorg/lib/libX11
+INHERIT=toolchain-funcs xorg-3
+IUSE=test abi_x86_32 abi_x86_64 abi_x86_x32 abi_mips_n32 abi_mips_n64 abi_mips_o32 abi_s390_32 abi_s390_64 doc
+KEYWORDS=~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos
+LICENSE=MIT
+RDEPEND=>=x11-libs/libxcb-1.11.1[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,abi_mips_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_s390_32(-)?,abi_s390_64(-)?] x11-misc/compose-tables !<xfce-base/xfce4-settings-4.16.3
+RESTRICT=!test? ( test )
+SLOT=0
+SRC_URI=https://www.x.org/releases/individual/lib/libX11-1.8.1.tar.xz
+_eclasses_=autotools 9e6965bfaa00f52cc61e0d4bc44c87b3 edos2unix 33e347e171066657f91f8b0c72ec8773 eutils 8f942ebdcf04334697649d4a0bf65a32 flag-o-matic 29a755b1291d64133634d80b0328f153 gnuconfig b6b3e92f8b8c996400074b5f61a59256 libtool 241a8f577b9781a42a7421e53448a44e multibuild d26d81f242cb193d899a72bca423d0bd multilib 5ca4e49abed8e3a2f7b56920eadee157 multilib-build 87f1b83e21a473787b821ef3d0437bf3 multilib-minimal 4b0f1857965db8869a729948d5277e0b strip-linguas ac3ee41ee2d31d8c41a77c0838320cc7 toolchain-funcs 1542e649be915f43f6908a9e93909961 wrapper 4a1902f969e5718126434fc35f3a0d9c xorg-3 38a663574d97f06b6b729046865c8fb6
+_md5_=67125dd0600207ebeba7ce6a49e1578f
diff --git a/metadata/pkg_desc_index b/metadata/pkg_desc_index
index 995231ba..9fc3f9b0 100644
--- a/metadata/pkg_desc_index
+++ b/metadata/pkg_desc_index
@@ -87,6 +87,7 @@ x11-base/xwayland 22.1.3-r100: Standalone X server running under Wayland
x11-drivers/nvidia-drivers 470.141.03: NVIDIA Accelerated Graphics Driver
x11-drivers/nvidia-drivers-legacy 390.154: NVIDIA Accelerated Graphics Driver
x11-libs/gtk+ 2.24.33-r10 3.24.29-r10: Gimp ToolKit +
+x11-libs/libX11 1.8.1-r10: X.Org X11 library
x11-misc/nvidia-prime 314: NVIDIA Prime Render Offload configuration and utilities
x11-misc/nvidia-settings 470.141.03-r1: NVIDIA Linux X11 Settings Utility
x11-misc/nvidia-settings-legacy 390.154: NVIDIA Linux X11 Settings Utility
diff --git a/x11-libs/libX11/Manifest b/x11-libs/libX11/Manifest
new file mode 100644
index 00000000..5a548468
--- /dev/null
+++ b/x11-libs/libX11/Manifest
@@ -0,0 +1 @@
+DIST libX11-1.8.1.tar.xz 1818460 BLAKE2B 7602b4d8c65ea3160f81096b4e022b5462e49d96b36dee70fe06e972329dc9d70bbd462e2079da03ba5647d7a72bf03e29aab23c60bcc206c95d770655622226 SHA512 2e36d2c47519e0cb2697f588c0ccdf73fbe75c2163f0855c78f7052dc9e920bca081f9d5e39c707a14067f101faef74fc758c8862eeba675b1535b43119d533a
diff --git a/x11-libs/libX11/files/150.patch b/x11-libs/libX11/files/150.patch
new file mode 100644
index 00000000..1c3b6bd7
--- /dev/null
+++ b/x11-libs/libX11/files/150.patch
@@ -0,0 +1,175 @@
+From 8808d16b0bc53e6c1e235d2fc714145b9adcf626 Mon Sep 17 00:00:00 2001
+From: Adam Jackson <ajax@redhat.com>
+Date: Fri, 5 Aug 2022 15:19:08 -0400
+Subject: [PATCH] Allow X*IfEvent() to reenter libX11
+
+The documentation for this family of functions very clearly says not to
+call into xlib in your predicate function, but historically single
+threaded apps could get away with it just fine, and now that we've
+forced thread-safety on the world such apps will now deadlock instead.
+That's not an acceptable regression even if the app is technically
+broken. This has been reported with XFCE and FVWM, and Motif's
+cut-and-paste code has the same bug by inspection, so this does need to
+be addressed.
+
+This change nerfs LockDisplay/UnlockDisplay while inside the critical
+bit of an IfEvent function. This is still safe in the sense that the
+display remains locked and no other thread should be able to change it
+from under us, but the loop that scans the event queue might not be
+robust against it being modified as a side effect of protocol emitted by
+the predicate callback. But that's not new, non-XInitThreads'd xlib
+would have the same caveat.
+
+Closes: xorg/lib/libx11#157
+---
+ include/X11/Xlibint.h | 1 +
+ src/ChkIfEv.c | 3 +++
+ src/IfEvent.c | 2 ++
+ src/OpenDis.c | 1 +
+ src/PeekIfEv.c | 2 ++
+ src/locking.c | 30 ++++++++++++++++++++++++++++++
+ 6 files changed, 39 insertions(+)
+
+diff --git a/include/X11/Xlibint.h b/include/X11/Xlibint.h
+index 6d880a65..46c9ac11 100644
+--- a/include/X11/Xlibint.h
++++ b/include/X11/Xlibint.h
+@@ -207,6 +207,7 @@ struct _XDisplay
+
+ XIOErrorExitHandler exit_handler;
+ void *exit_handler_data;
++ Bool in_ifevent;
+ };
+
+ #define XAllocIDs(dpy,ids,n) (*(dpy)->idlist_alloc)(dpy,ids,n)
+diff --git a/src/ChkIfEv.c b/src/ChkIfEv.c
+index 876a850e..327b5eaf 100644
+--- a/src/ChkIfEv.c
++++ b/src/ChkIfEv.c
+@@ -50,6 +50,7 @@ Bool XCheckIfEvent (
+ int n; /* time through count */
+
+ LockDisplay(dpy);
++ dpy->in_ifevent = True;
+ prev = NULL;
+ for (n = 3; --n >= 0;) {
+ for (qelt = prev ? prev->next : dpy->head;
+@@ -60,6 +61,7 @@ Bool XCheckIfEvent (
+ *event = qelt->event;
+ _XDeq(dpy, prev, qelt);
+ _XStoreEventCookie(dpy, event);
++ dpy->in_ifevent = False;
+ UnlockDisplay(dpy);
+ return True;
+ }
+@@ -78,6 +80,7 @@ Bool XCheckIfEvent (
+ /* another thread has snatched this event */
+ prev = NULL;
+ }
++ dpy->in_ifevent = False;
+ UnlockDisplay(dpy);
+ return False;
+ }
+diff --git a/src/IfEvent.c b/src/IfEvent.c
+index ead93dca..a0aed7e3 100644
+--- a/src/IfEvent.c
++++ b/src/IfEvent.c
+@@ -49,6 +49,7 @@ XIfEvent (
+ unsigned long qe_serial = 0;
+
+ LockDisplay(dpy);
++ dpy->in_ifevent = True;
+ prev = NULL;
+ while (1) {
+ for (qelt = prev ? prev->next : dpy->head;
+@@ -59,6 +60,7 @@ XIfEvent (
+ *event = qelt->event;
+ _XDeq(dpy, prev, qelt);
+ _XStoreEventCookie(dpy, event);
++ dpy->in_ifevent = False;
+ UnlockDisplay(dpy);
+ return 0;
+ }
+diff --git a/src/OpenDis.c b/src/OpenDis.c
+index 5017b040..e1bc2a30 100644
+--- a/src/OpenDis.c
++++ b/src/OpenDis.c
+@@ -189,6 +189,7 @@ XOpenDisplay (
+ dpy->xcmisc_opcode = 0;
+ dpy->xkb_info = NULL;
+ dpy->exit_handler_data = NULL;
++ dpy->in_ifevent = False;
+
+ /*
+ * Setup other information in this display structure.
+diff --git a/src/PeekIfEv.c b/src/PeekIfEv.c
+index 207cd119..c4e8af0d 100644
+--- a/src/PeekIfEv.c
++++ b/src/PeekIfEv.c
+@@ -50,6 +50,7 @@ XPeekIfEvent (
+ unsigned long qe_serial = 0;
+
+ LockDisplay(dpy);
++ dpy->in_ifevent = True;
+ prev = NULL;
+ while (1) {
+ for (qelt = prev ? prev->next : dpy->head;
+@@ -63,6 +64,7 @@ XPeekIfEvent (
+ _XStoreEventCookie(dpy, &copy);
+ *event = copy;
+ }
++ dpy->in_ifevent = False;
+ UnlockDisplay(dpy);
+ return 0;
+ }
+diff --git a/src/locking.c b/src/locking.c
+index ea5000e1..36530691 100644
+--- a/src/locking.c
++++ b/src/locking.c
+@@ -452,6 +452,32 @@ static void _XDisplayLockWait(
+ }
+ }
+
++static void _XLockDisplay(
++ Display *dpy
++ XTHREADS_FILE_LINE_ARGS
++ );
++
++static void _XIfEventLockDisplay(
++ Display *dpy
++ XTHREADS_FILE_LINE_ARGS
++ )
++{
++ /* assert(dpy->in_ifevent); */
++}
++
++static void _XIfEventUnlockDisplay(
++ Display *dpy
++ XTHREADS_FILE_LINE_ARGS
++ )
++{
++ if (dpy->in_ifevent)
++ return;
++
++ dpy->lock_fns->lock_display = _XLockDisplay;
++ dpy->lock_fns->unlock_display = _XUnlockDisplay;
++ UnlockDisplay(dpy);
++}
++
+ static void _XLockDisplay(
+ Display *dpy
+ XTHREADS_FILE_LINE_ARGS
+@@ -478,6 +504,10 @@ static void _XLockDisplay(
+ #endif
+ _XIDHandler(dpy);
+ _XSeqSyncFunction(dpy);
++ if (dpy->in_ifevent) {
++ dpy->lock_fns->lock_display = _XIfEventLockDisplay;
++ dpy->lock_fns->unlock_display = _XIfEventUnlockDisplay;
++ }
+ }
+
+ /*
+--
+GitLab
+
diff --git a/x11-libs/libX11/libX11-1.8.1-r10.ebuild b/x11-libs/libX11/libX11-1.8.1-r10.ebuild
new file mode 100644
index 00000000..7e1cbddf
--- /dev/null
+++ b/x11-libs/libX11/libX11-1.8.1-r10.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+XORG_DOC=doc
+XORG_MULTILIB=yes
+XORG_TARBALL_SUFFIX=xz
+inherit toolchain-funcs xorg-3
+
+# Note: please bump this with x11-misc/compose-tables
+DESCRIPTION="X.Org X11 library"
+
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ >=x11-libs/libxcb-1.11.1[${MULTILIB_USEDEP}]
+ x11-misc/compose-tables
+
+ !<xfce-base/xfce4-settings-4.16.3
+"
+DEPEND="${RDEPEND}
+ x11-base/xorg-proto
+ x11-libs/xtrans
+"
+BDEPEND="test? ( dev-lang/perl )"
+
+PATCHES=( "${FILESDIR}"/150.patch )
+
+src_configure() {
+ local XORG_CONFIGURE_OPTIONS=(
+ $(use_with doc xmlto)
+ $(use_enable doc specs)
+ --enable-ipv6
+ --without-fop
+ CPP="$(tc-getPROG CPP cpp)"
+ )
+ xorg-3_src_configure
+}
+
+src_install() {
+ xorg-3_src_install
+ rm -rf "${ED}"/usr/share/X11/locale || die
+}