Commit graph

176 commits

Author SHA1 Message Date
nyorain
8e34692250 render/vulkan: add Vulkan renderer
This new renderer is implemented with the existing wlr_renderer API
(which is known to be sub-optimal for some operations). It's not
used by default, but users can opt-in by setting WLR_RENDERER=vulkan.

The renderer depends on VK_EXT_image_drm_format_modifier and
VK_EXT_physical_device_drm.

Co-authored-by: Simon Ser <contact@emersion.fr>
Co-authored-by: Jan Beich <jbeich@FreeBSD.org>
2021-10-18 11:51:13 +02:00
Simon Ser
d9523faa76 build: add subproject fallback for wayland 2021-09-01 15:51:03 -04:00
Simon Ser
d48ffac56b build: remove "." from include dirs 2021-08-06 19:44:35 +02:00
ayaka
70fb21c35b backend: make DRM and libinput backends optional
Co-authored-by: Simon Ser <contact@emersion.fr>
2021-07-22 09:56:38 -04:00
Simon Ser
31db232704 build: use meson.global_build_root()
meson.build_root() is deprecated.

References: https://github.com/mesonbuild/meson/pull/8629
2021-06-25 10:01:25 -04:00
Simon Ser
0467a7523a build: bump version to 0.15.0 2021-06-23 14:30:57 +02:00
Kenny Levinsen
15c8453ba1 Revert "meson: Make private static library symbols local"
This reverts commit 28d23ba6bda4f799b8d6689555cd33a40adda17e.

The prelinking and symbol filtering pass breaks builds with link-time
optimization enabled.
2021-06-20 21:04:23 +02:00
Kenny Levinsen
cb6db86a28 meson: Make private static library symbols local
Static libraries are not affected by our symbol file, so private symbols
are globally visible by default.

Use objcopy to make symbols that we do not want to expose local.

Closes: https://github.com/swaywm/wlroots/issues/1892
Closes: https://github.com/swaywm/wlroots/issues/2952
2021-06-17 11:02:30 +02:00
Simon Ser
fb933d3204 backend/session: use drmIsKMS
This moves the magic incantation into libdrm and is clearer. See
[1] for details.

While at it, fixup the doc comment and improve logging.

[1]: 523b3658aa
2021-06-17 00:27:12 +02:00
Simon Ser
8ff435831f xdg-activation-v1: new protocol implementation
This implements the new xdg-activation-v1 protocol [1].

[1]: https://gitlab.freedesktop.org/wayland/wayland-protocols/-/merge_requests/50
2021-06-02 11:18:25 +02:00
Simon Ser
66d5805594 build: move wayland-protocols dep to protocol/ 2021-05-01 12:33:50 +02:00
ayaka
ed1924800d render: make GLES2 renderer optional
Allow selecting whether the GLES2 renderer gets enabled.

Co-authored-by: Simon Ser <contact@emersion.fr>
2021-04-17 16:39:40 +02:00
Simon Zeni
0d90dddfab render: introduce pixman renderer 2021-04-17 09:54:39 +02:00
Kenny Levinsen
95b657ba80 backend/session: Make libseat mandatory 2021-04-14 23:25:07 +02:00
Ryan Farley
b29ac8fbac util/uuid: replace with util/token, remove libuuid
Use 128-bit hexadecimal string tokens generated with /dev/urandom
instead of UUIDs for xdg-foreign handles, removing the libuuid
dependency. Update readme and CI. Closes #2830.

build: remove xdg-foreign feature

With no external dependencies required, there's no reason not to always
build it. Remove WLR_HAS_XDG_FOREIGN as well.
2021-04-11 19:09:36 +02:00
Kenny Levinsen
d50bbf0bbc backend/session: Remove logind backend
This is instead delegated to libseat.
2021-04-11 10:03:13 +02:00
Simon Ser
1eb38e0015 Remove WLR_HAS_XCB_ERRORS
wlroots' dependency on this library doesn't change the features
exposed to compositors. It's purely a wlroots implementation detail.
Thus downstream compositors shouldn't really care about it.

Introduce an "internal_features" dictionary to store the status of
such internal dependencies.
2021-04-09 21:54:38 +02:00
Simon Ser
1c10079a67 build: bump version to 0.14.0
We now bump the version number right after releases, so that a Git
snapshot is not mistaken for a previous version.

References: https://github.com/swaywm/wlroots/issues/2792
2021-04-08 08:53:07 +02:00
Simon Ser
69c71dbc8a build: bump to v0.13.0
References: https://github.com/swaywm/wlroots/issues/2778
2021-04-07 21:19:31 +02:00
Simon Ser
de5347d0f2 xwayland: require xcb-icccm
This dependency is already required by many other widely used X11
programs, such as i3, Qt, and other XWMs. So it should be available
on most systems.

X11 support can be pretty broken without xcb-icccm, with focus issues
for instance. Let's just remove this --please-break-my-desktop footgun
option.
2021-03-29 12:24:26 +02:00
Simon Ser
3695ae97b4 build: rollback -Wformat=2
Causes some build failures on Clang.

Fixes: 4b43aebdc7 ("build: add -Wformat=2 -Walloca")
2021-02-23 17:06:52 +01:00
Simon Ser
4b43aebdc7 build: add -Wformat=2 -Walloca 2021-02-23 16:41:26 +01:00
Simon Ser
38ec1c0e73 build: bump meson version to 0.56.0
Fixes this warning:

    WARNING: Project targeting '>=0.54.0' but tried to use feature introduced in '0.56.0': variables as dictionary.

Fixes: 6f873078d4 ("build: use dictionnary for features instead of configuration_data")
2021-02-15 23:45:26 +01:00
Simon Ser
27f65c2c77 build: set pkg-config variables for our features
this avoids having to parse the config.h file from builds systems
of projects using wlroots.
2021-02-15 16:32:33 +01:00
Simon Ser
fdd9088e05 build: set have_* dep variables for our features
This allows users to to something like this when wlroots is used as a
subproject:

    wlr_has_xwayland = wlroots.get_variable('have_xwayland')

Instead of having to parse conf_data from the subproject object.
2021-02-15 16:32:33 +01:00
Simon Ser
6f873078d4 build: use dictionnary for features instead of configuration_data
This allows us to easily iterate on all features and only deal with
bools.
2021-02-15 16:32:33 +01:00
Simon Ser
d595a4ebe3 build: remove extra whitespace 2021-02-08 14:57:41 +01:00
Simon Ser
8d76d3263d seat: use WL_SEAT_ERROR_CAPABILITY
Depends on [1].

[1]: https://gitlab.freedesktop.org/wayland/wayland/-/merge_requests/79
2021-02-08 13:30:21 +01:00
Simon Ser
672e8e99b7
build: use more consistent feature names in summary
Use the same name as the Meson option.
2021-01-12 10:49:33 +01:00
Simon Ser
248b8e647a
build: remove Clang workarounds
We have these disabled for all compilers anyways.
2021-01-11 16:13:53 +01:00
Ilia Bozhinov
37602e153b types: add wlr_xdg_foreign_registry 2021-01-05 20:32:56 +01:00
Ilia Bozhinov
bf4e2e0eac util: add support for generating UUIDs
Co-authored-by: Jason Francis <cycl0ps@tuta.io>
2021-01-05 20:32:56 +01:00
Simon Ser
858a1940b5 build: move wayland-egl dependency to examples/
Now that the Wayland backend has moved to wlr_swapchain, only
client examples use the dependency. Stop linking against wayland-egl
in the wlroots library.
2020-12-13 12:16:28 +01:00
Simon Ser
e18599b05e render/egl: stop including eglmesaext.h
This is a Mesa-specific header that was needed because some Wayland EGL
extensions were missing from the Khronos registry. Now that this has
been fixed [1] and Mesa [2] & glvnd [3] have sync'ed their headers, we
can drop this workaround.

[1]: https://github.com/KhronosGroup/EGL-Registry/pull/95
[2]: https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4953
[3]: https://gitlab.freedesktop.org/glvnd/libglvnd/-/merge_requests/225
2020-11-19 00:42:09 +01:00
Simon Ser
526ae5944c
build: improve summary via bool_yn
Shows YES/NO instead of 1/0, improves readability.
2020-11-15 23:15:49 +01:00
Simon Ser
aaa3fcf66f
backend/libinput: require libinput 1.14
We have the policy of requiring up-to-date dependencies instead of
adding conditionals for older versions. libinput 1.14 was published more
than 1 year ago.
2020-11-15 18:57:16 +01:00
Simon Ser
238d1c078f
Update version to 0.12.0 2020-11-08 15:01:44 +01:00
Kenny Levinsen
bad1e9afa8 session: Add libseat backend 2020-08-24 11:13:55 +02:00
Simon Ser
751a21d94f
Update version to 0.11.0 2020-07-16 00:27:23 +02:00
Julien Olivain
c2288a7b88
render/egl: include EGL/eglmesaext.h only if present
This patch will make the EGL renderer work on any EGL/GLESv2 driver
providing the EGL_WL_bind_wayland_display extensions.

Mesa used to declare provisional EGL_WL_bind_wayland_display directly
in <EGL/eglext.h>. Then, all unofficial extensions were moved to
<EGL/eglmesaext.h>, to have a cleaner implementation. See:
ab7bb10a2a

The extension was then approved at Khronos Group, and reached the
official <EGL/eglext.h>. See:
https://www.khronos.org/registry/EGL/extensions/WL/EGL_WL_bind_wayland_display.txt
aa9b63f3ab

In order to make sure the renderer will work on any version of any
implementation providing the extension, only include the mesa-specific
header if it's present.

Signed-off-by: Julien Olivain <juju@cotds.org>
2020-05-11 08:58:30 +02:00
Scott Anderson
906c0766df Remove libcap support
This is simply a false sense of security, and is worse than just using
setuid. CAP_SYS_ADMIN is an extremely serious capability that is
effectively as powerful as root.

It also required users to be in the input group, which allows any
process to keylog the entire system.
2020-04-29 10:39:09 +02:00
Simon Ser
f81aa6a172 build: use summary instead of message 2020-04-21 15:33:53 +02:00
Simon Ser
0b882475ad build: use meson.override_dependency
When built as a subproject, this removes the need for the parent project
to know about the dependency variable name.

This requires Meson 0.54.0.
2020-04-21 14:56:05 +02:00
Brian Ashworth
7e990a6bdf meson.build: update wayland requirement to 1.18
This updates the version requirement for wayland-server to 1.18, which
is needed for wl_global_remove and wl_global_set_user_data
2020-02-18 09:09:03 +01:00
Simon Ser
4b051aa926 meson: fix wayland-server minimum required version
Having 1.16 results in the following error when running the compositor:

    2019-04-27 17:30:50 - [wayland] wl_global_create: implemented version for 'wl_seat' higher than interface version (7 > 6)
    2019-04-27 17:30:50 - [sway/input/seat.c:428] seat_create:could not allocate seat

We require wayland-server >= 1.17 for wl_seat version 7.

Fixes: a671fc51d2 ("Advertise wl_seat version 7")
Fixes: a656e486f4 ("seat: fallback to v6 if libwayland 1.17 isn't available")
2020-02-04 22:44:02 +00:00
Simon Ser
1f722f5c80 build: replace version with soversion
This allows us to have a single number to update when doing a release.

This drops WLR_VERSION_API_* definitions.
2020-01-24 11:17:03 +01:00
Drew DeVault
57ffb35de0 Update version to 0.10.0 2020-01-22 13:22:04 -05:00
Jan Staněk
d9fdd28ac6 Honor the examples meson setting 2020-01-20 15:43:08 +01:00
Scott Anderson
062583ed58 Bump meson version to 0.51.2
There was an issue in 0.51.1 and earlier, where lists of dependencies
and disablers weren't acting like they should. Instead of disabling a
build, it would error out instead.

Changing this logic to work around it is annoying, so just bump the
version instead.
2020-01-14 12:48:41 +01:00
Drew DeVault
ebdbe177d6 Drop RDP backend
Users interested in remote access to wlroots compositors should use
wayvnc:

https://github.com/any1/wayvnc
2020-01-10 19:38:39 +01:00