Gentoo Archives: gentoo-commits

From: Jory Pratt <anarchy@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/musl:master commit in: x11-base/xorg-server/, x11-base/xorg-server/files/
Date: Tue, 08 May 2018 18:01:34
Message-Id: 1525802428.962a0b3ad3c4fb54d425235eed441fe213436c38.anarchy@gentoo
1 commit: 962a0b3ad3c4fb54d425235eed441fe213436c38
2 Author: Jory A. Pratt <anarchy <AT> gentoo <DOT> org>
3 AuthorDate: Tue May 8 18:00:28 2018 +0000
4 Commit: Jory Pratt <anarchy <AT> gentoo <DOT> org>
5 CommitDate: Tue May 8 18:00:28 2018 +0000
6 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=962a0b3a
7
8 x11-base/xorg-server - bug #653688 patch inclusion
9
10 ...t-pick-sRGB-config-for-32-bit-RGBA-visual.patch | 39 ++++
11 x11-base/xorg-server/xorg-server-1.19.5-r2.ebuild | 252 +++++++++++++++++++++
12 2 files changed, 291 insertions(+)
13
14 diff --git a/x11-base/xorg-server/files/xorg-server-1.19.5-glx-do-not-pick-sRGB-config-for-32-bit-RGBA-visual.patch b/x11-base/xorg-server/files/xorg-server-1.19.5-glx-do-not-pick-sRGB-config-for-32-bit-RGBA-visual.patch
15 new file mode 100644
16 index 0000000..d7e5e51
17 --- /dev/null
18 +++ b/x11-base/xorg-server/files/xorg-server-1.19.5-glx-do-not-pick-sRGB-config-for-32-bit-RGBA-visual.patch
19 @@ -0,0 +1,39 @@
20 +From c2954b16c8730c7ed8441fd8dba25900f3aed265 Mon Sep 17 00:00:00 2001
21 +From: =?UTF-8?q?Tapani=20P=C3=A4lli?= <tapani.palli@×××××.com>
22 +Date: Tue, 28 Nov 2017 09:23:29 +0200
23 +Subject: [PATCH] glx: do not pick sRGB config for 32-bit RGBA visual
24 +MIME-Version: 1.0
25 +Content-Type: text/plain; charset=UTF-8
26 +Content-Transfer-Encoding: 8bit
27 +
28 +This fixes blending issues seen with kwin and gnome-shell when
29 +32bit visual has sRGB capability set.
30 +
31 +Reviewed-by: Adam Jackson <ajax@××××××.com>
32 +Signed-off-by: Tapani Pälli <tapani.palli@×××××.com>
33 +Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103699
34 +Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103646
35 +Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103655
36 +---
37 + glx/glxscreens.c | 5 +++++
38 + 1 file changed, 5 insertions(+)
39 +
40 +diff --git a/glx/glxscreens.c b/glx/glxscreens.c
41 +index 73444152a..596d972e0 100644
42 +--- a/glx/glxscreens.c
43 ++++ b/glx/glxscreens.c
44 +@@ -271,6 +271,11 @@ pickFBConfig(__GLXscreen * pGlxScreen, VisualPtr visual)
45 + /* If it's the 32-bit RGBA visual, demand a 32-bit fbconfig. */
46 + if (visual->nplanes == 32 && config->rgbBits != 32)
47 + continue;
48 ++ /* If it's the 32-bit RGBA visual, do not pick sRGB capable config.
49 ++ * This can cause issues with compositors that are not sRGB aware.
50 ++ */
51 ++ if (visual->nplanes == 32 && config->sRGBCapable == GL_TRUE)
52 ++ continue;
53 + /* Can't use the same FBconfig for multiple X visuals. I think. */
54 + if (config->visualID != 0)
55 + continue;
56 +--
57 +2.17.0
58 +
59
60 diff --git a/x11-base/xorg-server/xorg-server-1.19.5-r2.ebuild b/x11-base/xorg-server/xorg-server-1.19.5-r2.ebuild
61 new file mode 100644
62 index 0000000..c3cd8c9
63 --- /dev/null
64 +++ b/x11-base/xorg-server/xorg-server-1.19.5-r2.ebuild
65 @@ -0,0 +1,252 @@
66 +# Copyright 1999-2017 Gentoo Foundation
67 +# Distributed under the terms of the GNU General Public License v2
68 +
69 +EAPI=5
70 +
71 +XORG_DOC=doc
72 +inherit xorg-2 multilib versionator flag-o-matic
73 +EGIT_REPO_URI="https://anongit.freedesktop.org/git/xorg/xserver.git"
74 +
75 +DESCRIPTION="X.Org X servers"
76 +SLOT="0/${PV}"
77 +KEYWORDS="arm"
78 +
79 +IUSE_SERVERS="dmx kdrive wayland xephyr xnest xorg xvfb"
80 +IUSE="${IUSE_SERVERS} debug +glamor ipv6 libressl minimal selinux +suid systemd tslib +udev unwind xcsecurity"
81 +
82 +CDEPEND=">=app-eselect/eselect-opengl-1.3.0
83 + !libressl? ( dev-libs/openssl:0= )
84 + libressl? ( dev-libs/libressl )
85 + >=x11-apps/iceauth-1.0.2
86 + >=x11-apps/rgb-1.0.3
87 + >=x11-apps/xauth-1.0.3
88 + x11-apps/xkbcomp
89 + >=x11-libs/libdrm-2.4.46
90 + >=x11-libs/libpciaccess-0.12.901
91 + >=x11-libs/libXau-1.0.4
92 + >=x11-libs/libXdmcp-1.0.2
93 + >=x11-libs/libXfont2-2.0.1
94 + >=x11-libs/libxkbfile-1.0.4
95 + >=x11-libs/libxshmfence-1.1
96 + >=x11-libs/pixman-0.27.2
97 + >=x11-libs/xtrans-1.3.5
98 + >=x11-misc/xbitmaps-1.0.1
99 + >=x11-misc/xkeyboard-config-2.4.1-r3
100 + dmx? (
101 + x11-libs/libXt
102 + >=x11-libs/libdmx-1.0.99.1
103 + >=x11-libs/libX11-1.1.5
104 + >=x11-libs/libXaw-1.0.4
105 + >=x11-libs/libXext-1.0.99.4
106 + >=x11-libs/libXfixes-5.0
107 + >=x11-libs/libXi-1.2.99.1
108 + >=x11-libs/libXmu-1.0.3
109 + x11-libs/libXrender
110 + >=x11-libs/libXres-1.0.3
111 + >=x11-libs/libXtst-1.0.99.2
112 + )
113 + glamor? (
114 + media-libs/libepoxy[X]
115 + >=media-libs/mesa-10.3.4-r1[egl,gbm]
116 + !x11-libs/glamor
117 + )
118 + kdrive? (
119 + >=x11-libs/libXext-1.0.5
120 + x11-libs/libXv
121 + )
122 + xephyr? (
123 + x11-libs/libxcb[xkb]
124 + x11-libs/xcb-util
125 + x11-libs/xcb-util-image
126 + x11-libs/xcb-util-keysyms
127 + x11-libs/xcb-util-renderutil
128 + x11-libs/xcb-util-wm
129 + )
130 + !minimal? (
131 + >=x11-libs/libX11-1.1.5
132 + >=x11-libs/libXext-1.0.5
133 + >=media-libs/mesa-10.3.4-r1
134 + )
135 + tslib? ( >=x11-libs/tslib-1.0 )
136 + udev? ( >=virtual/udev-150 )
137 + unwind? ( sys-libs/libunwind )
138 + wayland? (
139 + >=dev-libs/wayland-1.3.0
140 + media-libs/libepoxy
141 + >=dev-libs/wayland-protocols-1.1
142 + )
143 + >=x11-apps/xinit-1.3.3-r1
144 + systemd? (
145 + sys-apps/dbus
146 + sys-apps/systemd
147 + )"
148 +
149 +DEPEND="${CDEPEND}
150 + sys-devel/flex
151 + >=x11-proto/bigreqsproto-1.1.0
152 + >=x11-proto/compositeproto-0.4
153 + >=x11-proto/damageproto-1.1
154 + >=x11-proto/fixesproto-5.0
155 + >=x11-proto/fontsproto-2.1.3
156 + >=x11-proto/glproto-1.4.17-r1
157 + >=x11-proto/inputproto-2.3
158 + >=x11-proto/kbproto-1.0.3
159 + >=x11-proto/randrproto-1.5.0
160 + >=x11-proto/recordproto-1.13.99.1
161 + >=x11-proto/renderproto-0.11
162 + >=x11-proto/resourceproto-1.2.0
163 + >=x11-proto/scrnsaverproto-1.1
164 + >=x11-proto/trapproto-3.4.3
165 + >=x11-proto/videoproto-2.2.2
166 + >=x11-proto/xcmiscproto-1.2.0
167 + >=x11-proto/xextproto-7.2.99.901
168 + >=x11-proto/xf86dgaproto-2.0.99.1
169 + >=x11-proto/xf86vidmodeproto-2.2.99.1
170 + >=x11-proto/xineramaproto-1.1.3
171 + >=x11-proto/xproto-7.0.31
172 + >=x11-proto/presentproto-1.0
173 + >=x11-proto/dri2proto-2.8
174 + >=x11-proto/dri3proto-1.0
175 + dmx? (
176 + >=x11-proto/dmxproto-2.2.99.1
177 + doc? (
178 + || (
179 + www-client/links
180 + www-client/lynx
181 + www-client/w3m
182 + )
183 + )
184 + )
185 + !minimal? (
186 + >=x11-proto/xf86driproto-2.1.0
187 + )"
188 +
189 +RDEPEND="${CDEPEND}
190 + selinux? ( sec-policy/selinux-xserver )
191 + !x11-drivers/xf86-video-modesetting
192 +"
193 +
194 +PDEPEND="
195 + xorg? ( >=x11-base/xorg-drivers-$(get_version_component_range 1-2) )"
196 +
197 +REQUIRED_USE="!minimal? (
198 + || ( ${IUSE_SERVERS} )
199 + )
200 + xephyr? ( kdrive )"
201 +
202 +#UPSTREAMED_PATCHES=(
203 +# "${WORKDIR}/patches/"
204 +#)
205 +
206 +PATCHES=(
207 + "${UPSTREAMED_PATCHES[@]}"
208 + "${FILESDIR}"/${PN}-1.12-unloadsubmodule.patch
209 + # needed for new eselect-opengl, bug #541232
210 + "${FILESDIR}"/${PN}-1.18-support-multiple-Files-sections.patch
211 + "${FILESDIR}"/${PN}-1.19.4-sysmacros.patch #633530
212 + "${FILESDIR}"/${PN}-1.19.5-glx-do-not-pick-sRGB-config-for-32-bit-RGBA-visual.patch #653688
213 + "${FILESDIR}"/${PN}-1.17.4-arm-musl.patch
214 +)
215 +
216 +pkg_pretend() {
217 + # older gcc is not supported
218 + [[ "${MERGE_TYPE}" != "binary" && $(gcc-major-version) -lt 4 ]] && \
219 + die "Sorry, but gcc earlier than 4.0 will not work for xorg-server."
220 +}
221 +
222 +pkg_setup() {
223 + if use wayland && ! use glamor; then
224 + ewarn "glamor is necessary for acceleration under Xwayland."
225 + ewarn "Performance may be unacceptable without it."
226 + fi
227 +}
228 +
229 +src_configure() {
230 + # localstatedir is used for the log location; we need to override the default
231 + # from ebuild.sh
232 + # sysconfdir is used for the xorg.conf location; same applies
233 + # NOTE: fop is used for doc generating; and I have no idea if Gentoo
234 + # package it somewhere
235 + XORG_CONFIGURE_OPTIONS=(
236 + $(use_enable ipv6)
237 + $(use_enable debug)
238 + $(use_enable dmx)
239 + $(use_enable glamor)
240 + $(use_enable kdrive)
241 + $(use_enable kdrive kdrive-kbd)
242 + $(use_enable kdrive kdrive-mouse)
243 + $(use_enable kdrive kdrive-evdev)
244 + $(use_enable suid install-setuid)
245 + $(use_enable tslib)
246 + $(use_enable unwind libunwind)
247 + $(use_enable wayland xwayland)
248 + $(use_enable !minimal record)
249 + $(use_enable !minimal xfree86-utils)
250 + $(use_enable !minimal dri)
251 + $(use_enable !minimal dri2)
252 + $(use_enable !minimal glx)
253 + $(use_enable xcsecurity)
254 + $(use_enable xephyr)
255 + $(use_enable xnest)
256 + $(use_enable xorg)
257 + $(use_enable xvfb)
258 + $(use_enable udev config-udev)
259 + $(use_with doc doxygen)
260 + $(use_with doc xmlto)
261 + $(use_with systemd systemd-daemon)
262 + $(use_enable systemd systemd-logind)
263 + --enable-libdrm
264 + --sysconfdir="${EPREFIX}"/etc/X11
265 + --localstatedir="${EPREFIX}"/var
266 + --with-fontrootdir="${EPREFIX}"/usr/share/fonts
267 + --with-xkb-output="${EPREFIX}"/var/lib/xkb
268 + --disable-config-hal
269 + --disable-linux-acpi
270 + --without-dtrace
271 + --without-fop
272 + --with-os-vendor=Gentoo
273 + --with-sha1=libcrypto
274 + )
275 +
276 + xorg-2_src_configure
277 +}
278 +
279 +src_install() {
280 + xorg-2_src_install
281 +
282 + server_based_install
283 +
284 + if ! use minimal && use xorg; then
285 + # Install xorg.conf.example into docs
286 + dodoc "${AUTOTOOLS_BUILD_DIR}"/hw/xfree86/xorg.conf.example
287 + fi
288 +
289 + newinitd "${FILESDIR}"/xdm-setup.initd-1 xdm-setup
290 + newinitd "${FILESDIR}"/xdm.initd-11 xdm
291 + newconfd "${FILESDIR}"/xdm.confd-4 xdm
292 +
293 + # install the @x11-module-rebuild set for Portage
294 + insinto /usr/share/portage/config/sets
295 + newins "${FILESDIR}"/xorg-sets.conf xorg.conf
296 +}
297 +
298 +pkg_postinst() {
299 + # sets up libGL and DRI2 symlinks if needed (ie, on a fresh install)
300 + eselect opengl set xorg-x11 --use-old
301 +}
302 +
303 +pkg_postrm() {
304 + # Get rid of module dir to ensure opengl-update works properly
305 + if [[ -z ${REPLACED_BY_VERSION} && -e ${EROOT}/usr/$(get_libdir)/xorg/modules ]]; then
306 + rm -rf "${EROOT}"/usr/$(get_libdir)/xorg/modules
307 + fi
308 +}
309 +
310 +server_based_install() {
311 + if ! use xorg; then
312 + rm "${ED}"/usr/share/man/man1/Xserver.1x \
313 + "${ED}"/usr/$(get_libdir)/xserver/SecurityPolicy \
314 + "${ED}"/usr/$(get_libdir)/pkgconfig/xorg-server.pc \
315 + "${ED}"/usr/share/man/man1/Xserver.1x
316 + fi
317 +}