From nobody Tue Apr 16 05:11:23 2024 X-Original-To: dev-commits-ports-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VJXFT2jkfz5Hpb3; Tue, 16 Apr 2024 05:11:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VJXFR31xWz4d8s; Tue, 16 Apr 2024 05:11:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713244283; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ptYXx/lEQpAaXCg/wWve71GZd8R/aAWWwKUzEvS/gUc=; b=gKJWqLVLK97yf7SdPmes8A3lolgn5caNiKmfk6zpflzhtpsznhWzpDjxU/zn930VFrqbYQ tsIM2I30PL5zqWVLWoi9Xmn9EDbcEebYxBPZToA5t+7rv8aSGjg9y96bDtCG71wamjKt9G P6A7J+81ugD+KTT4X7B7slbMmLEVQqO07Q3wFKd9JJ/3igmych7hOOG1fy6qqFLas5Ttq/ yRrmH19dusP626VhVVSeSNd0QVFQhHExzDRJA+jOgsH7IUje1iOmrOvTGquROAnpjQCvz8 chTzg/1zfSMPRw2uLYfrZI9T8sUgm6HjiEkyjyNrrnvD2XIqOyxWo5WeIZGYGg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713244283; a=rsa-sha256; cv=none; b=BkxXm5IL2I6sZs7sHlSwtFGh8PTDo4KJHBfqQXLhn5TaFiEsIM7MCBxQAhNq6NPULFG9Ct rXas/KNn7p/mGvJ3udLM982Oaj2UdZKl2XwjYb8VZHpETqOZyAMm+BtAerJgT3qK3nKAt3 i0zXxLWuf+aHPT7KZMbUYGUHR69lrmxR78dyXLIuEJDoGICn3TukjhPv590A78saUPUDJE MDyg8RpqiXPpb6B7ozjMOu5vz4TUzgpcdzpxM+7TwGi39wi0oVgSZUlYiiITmp74GBJlWr MjFWV77TT9qpOKgRwstIalSQ5NWksV/RewtiL7/dLXF8V1AFV0vXwrRQ6jVvow== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713244283; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ptYXx/lEQpAaXCg/wWve71GZd8R/aAWWwKUzEvS/gUc=; b=klogazHRWzHAojQIx9Ua7h6RISkh9o+tB0Q7ZpgS6wDDcYJ3ndRhw0r7Acn9hxWFMOr9vy aNqtKbvjtW9AfqtRwx3+xxT+dsq2JnZS5qorSnOWcLVcmMrmxuXLecnk/dth5I75ns+dul XcNqqSLAZzwLfHiHZRL0css7bwUUSUeJs+9ztwlY3JhoajdfJgUuKbqHcuJlVhnYBDH92n ZaE94RVsbfcPdyFBrf+0GZJURA77dmqITiITxuEYRZ2+MLWrM2lI0jZ2FCRt0ZJVbQGiuF A0YALXcSaqHnJa5lH4siJVJULkYXWJ/nXIBhOk644zKo26LV4p7IbtkI5/Cn/A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4VJXFR2b7CzVgC; Tue, 16 Apr 2024 05:11:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43G5BNKk006296; Tue, 16 Apr 2024 05:11:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43G5BN1G006292; Tue, 16 Apr 2024 05:11:23 GMT (envelope-from git) Date: Tue, 16 Apr 2024 05:11:23 GMT Message-Id: <202404160511.43G5BN1G006292@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-branches@FreeBSD.org From: Emmanuel Vadot Subject: git: f0a7455052d8 - 2024Q2 - x11-servers/xorg-server: Add upstream patch for xkbcomp directory List-Id: Commits to the quarterly branches of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-branches@freebsd.org Sender: owner-dev-commits-ports-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: manu X-Git-Repository: ports X-Git-Refname: refs/heads/2024Q2 X-Git-Reftype: branch X-Git-Commit: f0a7455052d887a8e832013643bc1e3ca2386b0d Auto-Submitted: auto-generated The branch 2024Q2 has been updated by manu: URL: https://cgit.FreeBSD.org/ports/commit/?id=f0a7455052d887a8e832013643bc1e3ca2386b0d commit f0a7455052d887a8e832013643bc1e3ca2386b0d Author: Emmanuel Vadot AuthorDate: 2024-04-09 15:25:10 +0000 Commit: Emmanuel Vadot CommitDate: 2024-04-16 05:11:12 +0000 x11-servers/xorg-server: Add upstream patch for xkbcomp directory Add a patch commited upstream but not present in any releases (except Xwayland ones) as xorg-server releases stopped a while ago. This adds a fallback to use $XDG_RUNTIME_DIR for xkbcomp result file if the user can't write to the configured directory, which is unlikely for xorg-server as it's SUID but it is likely for xephyr or xvfb. While here use the meson default for xkb_dir as it's the same as the one we provide and use also the default for xkb_output_dir which defaults to xkb_dir/compiled which is a link to /var/lib/xkb (setup by the xkeyboard-config port). Differential Revision: https://reviews.freebsd.org/D44697 Reviewed by: bapt Sponsored by: Beckhoff Automation GmbH & Co. KG (cherry picked from commit 5c3c7500abd37116903994674f562c603a29aec1) --- x11-servers/xorg-server/Makefile | 6 +---- x11-servers/xorg-server/files/patch-xkb_ddxLoad.c | 30 +++++++++++++++++++++++ x11-servers/xorg-server/pkg-plist | 2 -- 3 files changed, 31 insertions(+), 7 deletions(-) diff --git a/x11-servers/xorg-server/Makefile b/x11-servers/xorg-server/Makefile index 9939340ec737..ec5deabbea4b 100644 --- a/x11-servers/xorg-server/Makefile +++ b/x11-servers/xorg-server/Makefile @@ -1,5 +1,6 @@ PORTNAME= xorg PORTVERSION= 21.1.12 +PORTREVISION= 1 PORTEPOCH= 1 CATEGORIES= x11-servers MASTER_SITES= XORG/individual/xserver @@ -34,7 +35,6 @@ PKGMESSAGE= BINARY_NAME= ${FLAVOR:C/^(.).*/\1/:tu}${FLAVOR:C/^.//} PLIST_FILES= bin/${BINARY_NAME} \ share/man/man1/${BINARY_NAME}.1.gz -PLIST_DIRS= /var/lib/xkb /var/lib .endif DESCR= ${.CURDIR}/pkg-descr-${FLAVOR} @@ -53,8 +53,6 @@ MESON_ARGS+= -Dxwin=false \ -Dfallback_input_driver=libinput \ -Ddocs=false \ -Dxcsecurity=true \ - -Dxkb_dir=${LOCALBASE}/share/X11/xkb \ - -Dxkb_output_dir=/var/lib/xkb \ -D${FLAVOR}=true .for f in ${FLAVORS:N${FLAVOR}} @@ -126,13 +124,11 @@ post-install: @${MKDIR} ${STAGEDIR}${PREFIX}/share/X11/xorg.conf.d @${INSTALL_DATA} ${FILESDIR}/20-evdev-kbd.conf \ ${STAGEDIR}${PREFIX}/share/X11/xorg.conf.d - ${MKDIR} -p ${STAGEDIR}/var/lib/xkb .else post-install: ${RM} -r ${STAGEDIR}${PREFIX}/lib/xorg/protocol.txt ${RMDIR} ${STAGEDIR}${PREFIX}/lib/xorg ${RM} ${STAGEDIR}${PREFIX}/share/man/man1/Xserver.1 - ${MKDIR} -p ${STAGEDIR}/var/lib/xkb .endif .include diff --git a/x11-servers/xorg-server/files/patch-xkb_ddxLoad.c b/x11-servers/xorg-server/files/patch-xkb_ddxLoad.c new file mode 100644 index 000000000000..509c70b6a680 --- /dev/null +++ b/x11-servers/xorg-server/files/patch-xkb_ddxLoad.c @@ -0,0 +1,30 @@ +--- xkb/ddxLoad.c.orig 2024-04-03 20:50:12 UTC ++++ xkb/ddxLoad.c +@@ -31,6 +31,7 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. + #include + + #include ++#include + #include + #include + #include +@@ -70,9 +71,17 @@ OutputDirectory(char *outdir, size_t size) + /* Can we write an xkm and then open it too? */ + if (access(XKM_OUTPUT_DIR, W_OK | X_OK) == 0) { + directory = XKM_OUTPUT_DIR; +- if (XKM_OUTPUT_DIR[strlen(XKM_OUTPUT_DIR) - 1] != '/') +- pathsep = "/"; ++ } else { ++ const char *xdg_runtime_dir = getenv("XDG_RUNTIME_DIR"); ++ ++ if (xdg_runtime_dir && xdg_runtime_dir[0] == '/' && ++ access(xdg_runtime_dir, W_OK | X_OK) == 0) ++ directory = xdg_runtime_dir; + } ++ ++ if (directory && directory[strlen(directory) - 1] != '/') ++ pathsep = "/"; ++ + #else + directory = Win32TempDir(); + pathsep = "\\"; diff --git a/x11-servers/xorg-server/pkg-plist b/x11-servers/xorg-server/pkg-plist index d99baab25f6b..b920012e58ba 100644 --- a/x11-servers/xorg-server/pkg-plist +++ b/x11-servers/xorg-server/pkg-plist @@ -189,5 +189,3 @@ share/X11/xorg.conf.d/20-evdev-kbd.conf share/aclocal/xorg-server.m4 @dir etc/X11/xorg.conf.d @dir %%FONTPATHD%% -@dir /var/lib/xkb -@dir /var/lib