No description
  • C 94.2%
  • Python 2.2%
  • Roff 1.2%
  • Objective-C 1%
  • Meson 0.9%
  • Other 0.3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jeremy Huddleston Sequoia dd5edd037b rootless: Remove ROOTLESS_WORKAROUND
XQuartz was the last consumer of this 2007 workaround, which made getDrawableDamageRef() route a non-viewable window's
damage to the screen damage list instead of the window pixmap's.  Because the answer then changed as a window's
viewability changed, it was a source of exactly the register/unregister list mismatch the previous commit addresses --
CrushTree() clears ->viewable before unrealizing, so a window's damage was inserted on one list and looked for on
another during teardown.

It was disabled for XWin in 20701522be for breaking Composite and removed entirely in
c89f0521044083a11d538ebfeaabee6fc7fb9a03, but that removal was reverted in de32d4dcf5
after a regression report, pending a proper fix in the damage layer.  That fix is now in place, so drop the workaround.

Fixes: https://github.com/XQuartz/XQuartz/issues/406

Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2277>
(cherry picked from commit cfbc5224a6)
(cherry picked from commit 029735e8a254ed2dd5c565878eb946f1ef684fa1)
(cherry picked from commit 0939e0d745c0ee86e603b23b09cac7ea5e632801)

Port notes
----------

This brings our tree in line with xorg/main, where ROOTLESS_WORKAROUND no longer
occurs at all. Jeremy Huddleston removed it there; this is that change, not a new
proposal.

Scope: the define is set only under `if build_rootless`, and build_rootless is set
only for build_xquartz (meson.build). In a normal -Dwerror=true build of this tree the
generated dix-config.h contains no ROOTLESS_WORKAROUND, so the #ifdef block in
miext/damage/damage.c does not compile there. The affected configuration is macOS
XQuartz.

History: the removal was reverted in de32d4dcf5 after a
regression report, pending a proper fix in the damage layer. That fix has since landed
as #3793 ("use drawable pointer instead of list head pointer"), which is what the
original commit message above refers to. Nothing re-established the workaround's
necessity afterwards: it returned in 2019 only because ecf62b7ba6 added the meson build
and carried the define over from configure.ac, without referring to the 2011 report.

Not verified here: that XQuartz on macOS runs without the workaround. applewm is not
available on this Linux host and no CI lane exercises it.

Not a backport candidate: this removes a workaround rather than fixing a defect.
It corrects no crash, no memory error and no security issue, so it must not be
carried to release/25.2, 25.1 or 25.0. Per the backport policy a release branch takes
bugfixes, not cleanups. If a release branch ever needs this, it has to be a deliberate
maintainer decision with its own justification - not a consequence of this port.
2026-10-02 16:58:01 +02:00
.github ci: use release/** pattern for PR CI to cover future release branches 2026-10-01 15:07:53 +02:00
.vscode lint: Add .clang-tidy and analyzer scripts 2026-05-26 12:15:17 +02:00
config meson: convert remaining foo == a or foo == b to foo in [a, b] style 2026-10-02 10:07:37 +02:00
dix RegionValidate: Fix double free of badreg->data on the error path 2026-10-01 18:52:29 +02:00
doc doc: Xnamespace-protocol: fix stale attribute names in CreateNamespace/§8 2026-07-03 20:05:08 +02:00
exa exa: silence -Wold-style-declaration warning from gcc 16 2026-10-01 11:29:50 +02:00
fb fb: Don't widen the planemask over padding bits when ROOTLESS_SAFEALPHA is set 2026-09-30 19:06:39 +02:00
glamor glamor: fix memleak in error path of glamor_link_glsl_prog() 2026-09-28 17:09:34 +02:00
hw kdrive/modesetting: Fix hw cursor vt switch 2026-10-02 16:24:52 +02:00
include rootless: Remove ROOTLESS_WORKAROUND 2026-10-02 16:58:01 +02:00
man Disable font server connections by default 2026-09-29 18:24:47 +02:00
mi DPMS: Don't wake display from input when timeouts are disabled 2026-10-02 12:35:19 +02:00
miext rootless: Remove ROOTLESS_WORKAROUND 2026-10-02 16:58:01 +02:00
msutil treewide: Add and use fallbacks for libdrm and libgbm 2026-09-09 11:33:33 +02:00
os darwin: Set thread priorities to user interactive or user initiated as appropriate 2026-09-30 19:24:05 +02:00
test test/pyxtest: allow for extra arguments in the xserver fixture 2026-10-02 15:48:32 +02:00
Xext xkb: Guard XkbAdjustGroup() against a keymap with no groups 2026-10-01 19:01:38 +02:00
.clang-tidy lint: Add .clang-tidy and analyzer scripts 2026-05-26 12:15:17 +02:00
.dir-locals.el
.git-blame-ignore-revs
.gitignore lint: Add .clang-tidy and analyzer scripts 2026-05-26 12:15:17 +02:00
.mailmap
CoC.md it's time to add a CoC (code of conduct) 2025-06-12 17:21:47 +02:00
CODE_OF_CONDUCT.md it's time to add a CoC (code of conduct) 2025-06-12 17:21:47 +02:00
CODE_OVERVIEW.md composite: move it under Xext/ 2026-06-17 07:50:13 +02:00
CONTRIBUTING.md fix minor spelling mistake in contributing guidelines 2025-09-05 15:05:37 +02:00
COPYING COPYING: update copyright dates/holders for remaining existing licenses 2026-06-12 18:24:49 +02:00
HISTORY.md HISTORY.md: add brief overview of the XLibre fork 2025-07-25 08:06:47 -04:00
meson.build meson: check cpu_family() instead of cpu() 2026-10-02 14:48:19 +02:00
meson_options.txt kdrive: Add Xmodesetting X server 2026-10-01 13:30:12 +02:00
NEWS NEWS: add 25.2.0 release entry 2026-06-19 19:24:57 +02:00
README.md README: add seatd operation to README 2026-06-23 18:37:34 +02:00
xlibre-server.pc.in xorg-server.pc: add more variables for easier driver builds 2026-01-08 16:57:10 +01:00
xorg-server.m4 xorg-server.m4: add helper macros for driver builds 2026-01-08 17:17:12 +01:00
xorg-server.pc.in xorg-server.pc: add more variables for easier driver builds 2026-01-08 16:57:10 +01:00
xserver.ent.in

XLibre Xserver

The XLibre Xserver is the community-managed display server for the X Window System Protocol Version 11 (Wikipedia), in short, X11.

1 year of XLibre screenshot
One Year of XLibre. See more liberated screens here.

Selected Features

  • All the good things from X.Org Server, including its unreleased features
  • TearFree modesetting by default and optionally atomic modesetting
  • Support for the Nvidia drivers 340, 390, 470, 570, and newer
  • Xnamespace extension for separating X clients
  • Support for seat management via seatd besides systemd-logind
  • Xfbdev, the generic framebuffer Xserver for Linux
  • CI builds for several BSDs, Linux, MacOS, and Microsoft Windows
  • Active community, cleanups, fixes, and development based on merit

To learn more about the features and mission of XLibre, please visit our homepage.

Switching to XLibre

The easiest way to install and run XLibre is to use your distribution's provided packages. Please see the Are We XLibre Yet? - (X11Libre/xserver Wiki) page for a list of the available options. If there is no option, then go on with building and installing XLibre from source.

Building XLibre

After cloning the Xserver repository or unpacking the sources and installing the dependencies, change into the source directory and run the Meson build tool:

cd "<source dir of xserver>"
meson setup <prefix> build <meson_options>
ninja -C build install

You may specify the install <prefix> with, for example, --prefix="$(pwd)/image" and add build time <meson_options> like so: -Dxnest=false. You may also want to build and install some graphics and input drivers. Please refer to the Building XLibre (X11Libre/xserver Wiki) page for more details.

Configuring XLibre

Until XLibre releases its own, you can find a detailed description of the configuration on the Configuration - Xorg (ArchWiki) page. If you have built and installed XLibre yourself, then change into the <prefix> directory with cd <prefix> and create a directory etc/X11 with a file xorg.conf and adjust it accordingly.

Starting with version 25.0.0.16, the proprietary Nvidia driver is autodetected and handled internally without any special configuration. Please see the Compatibility of XLibre (X11Libre/xserver Wiki) page for more details on the Nvidia driver and compatibility in general.

Running XLibre

If you installed XLibre using your distribution's provided packages, then the Xserver is usually started by init (Wikipedia) on system start. On other systems it should be possible to manually start XLibre with user permissions by invoking startx. Please refer to man startx for how to use it.

If you have built and installed XLibre yourself, then you may want to shutdown other Xservers, change into the <prefix> directory, and create a simple testx.sh file with the following contents:

#!/bin/sh
./bin/X :1 vt8 -logfile /dev/stdout &
_pid=$!
sleep 10 && kill $_pid

You can adjust the :1 vt8 and other options in the testx.sh file as detailed in man Xorg. Make the testx.sh executable and run it:

chmod 0770 testx.sh
./testx.sh

This should give you 10 glorious seconds of a black and beautiful and empty screen. Afterwards the Xserver complains about being killed, but there should be no other critical errors for a "test passed." For more details, please see Building XLibre (X11Libre/xserver Wiki).

If you are using seatd for rootless operation instead of (e)logind, create the following file named .xserverrc in your home directory:

#!/bin/sh
exec X -keeptty "$@"

Then, run chmod +x ~/.xserverrc.

I want to help!

That's great; there's enough to do for everyone. You may consider one of the many ideas and feature requests out there. To help in testing, you may consider becoming an XLibre Test Driver. Please also have a look at the good first and help wanted issues and the Liberated Screens.

If you want to work on anything, just let us know. If you have any questions, just ask. Thank you!

Contact

XLibre Discussions at GitHub | XLibre mailing list at FreeLists | @x11dev channel at Telegram | #xlibredev space at Matrix | XLibre security contact at GitHub