fa9b61004b
Running with WLR_BACKENDS=headless, there is no keyboard device. Avoid crashes like so: ../tinywl/tinywl.c:136:2: runtime error: member access within null pointer of type 'struct wlr_keyboard' ../tinywl/tinywl.c:136:2: runtime error: member access within null pointer of type 'struct wlr_keyboard' AddressSanitizer:DEADLYSIGNAL ================================================================= ==331107==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000120 (pc 0x556ed03e4e99 bp 0x7ffce834bc10 sp 0x7ffce834bbb0 T0) ==331107==The signal is caused by a READ memory access. ==331107==Hint: address points to the zero page. #0 0x556ed03e4e99 in focus_view ../tinywl/tinywl.c:136 #1 0x556ed03eb3be in xdg_toplevel_map ../tinywl/tinywl.c:603 #2 0x7f75d6f768db in wlr_signal_emit_safe ../util/signal.c:29 #3 0x7f75d6e9cac7 in xdg_surface_role_commit ../types/xdg_shell/wlr_xdg_surface.c:315 #4 0x7f75d6eb6944 in surface_commit_state ../types/wlr_compositor.c:466 #5 0x7f75d6eb7b02 in surface_handle_commit ../types/wlr_compositor.c:523 #6 0x7f75d5714d49 (/usr/lib/libffi.so.8+0x6d49) #7 0x7f75d5714266 (/usr/lib/libffi.so.8+0x6266) #8 0x7f75d68cb322 (/usr/lib/libwayland-server.so.0+0xd322) #9 0x7f75d68c65cb (/usr/lib/libwayland-server.so.0+0x85cb) #10 0x7f75d68c91c9 in wl_event_loop_dispatch (/usr/lib/libwayland-server.so.0+0xb1c9) #11 0x7f75d68c6d36 in wl_display_run (/usr/lib/libwayland-server.so.0+0x8d36) #12 0x556ed03eef55 in main ../tinywl/tinywl.c:905 #13 0x7f75d5d2330f in __libc_start_call_main (/usr/lib/libc.so.6+0x2d30f) #14 0x7f75d5d233c0 in __libc_start_main@GLIBC_2.2.5 (/usr/lib/libc.so.6+0x2d3c0) #15 0x556ed03e46e4 in _start (/home/simon/src/wlroots/build/tinywl/tinywl+0x136e4) |
||
---|---|---|
.builds | ||
backend | ||
docs | ||
examples | ||
include | ||
protocol | ||
render | ||
tinywl | ||
types | ||
util | ||
xcursor | ||
xwayland | ||
.editorconfig | ||
.gitignore | ||
.gitlab-ci.yml | ||
CONTRIBUTING.md | ||
LICENSE | ||
meson.build | ||
meson_options.txt | ||
README.md | ||
wlroots.syms |
wlroots
Pluggable, composable, unopinionated modules for building a Wayland compositor; or about 60,000 lines of code you were going to write anyway.
- wlroots provides backends that abstract the underlying display and input hardware, including KMS/DRM, libinput, Wayland, X11, and headless backends, plus any custom backends you choose to write, which can all be created or destroyed at runtime and used in concert with each other.
- wlroots provides unopinionated, mostly standalone implementations of many Wayland interfaces, both from wayland.xml and various protocol extensions. We also promote the standardization of portable extensions across many compositors.
- wlroots provides several powerful, standalone, and optional tools that implement components common to many compositors, such as the arrangement of outputs in physical space.
- wlroots provides an Xwayland abstraction that allows you to have excellent Xwayland support without worrying about writing your own X11 window manager on top of writing your compositor.
- wlroots provides a renderer abstraction that simple compositors can use to avoid writing GL code directly, but which steps out of the way when your needs demand custom rendering code.
wlroots implements a huge variety of Wayland compositor features and implements them right, so you can focus on the features that make your compositor unique. By using wlroots, you get high performance, excellent hardware compatibility, broad support for many wayland interfaces, and comfortable development tools - or any subset of these features you like, because all of them work independently of one another and freely compose with anything you want to implement yourself.
Check out our wiki to get started with wlroots. Join our IRC channel: #sway-devel on Libera Chat.
A variety of wrapper libraries are available for using it with your favorite programming language.
Building
Install dependencies:
- meson
- wayland
- wayland-protocols
- EGL and GLESv2 (optional, for the GLES2 renderer)
- Vulkan loader, headers and glslang (optional, for the Vulkan renderer)
- libdrm
- GBM
- libinput (optional, for the libinput backend)
- xkbcommon
- udev
- pixman
- libseat
If you choose to enable X11 support:
- xwayland (build-time only, optional at runtime)
- libxcb
- libxcb-render-util
- libxcb-wm
- libxcb-errors (optional, for improved error reporting)
Run these commands:
meson build/
ninja -C build/
Install like so:
sudo ninja -C build/ install
Contributing
See CONTRIBUTING.md.