1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
{ lib, stdenv, fetchurl, fetchpatch, meson, ninja, pkg-config, wayland-scanner
, python3, wayland, libGL, mesa, libxkbcommon, cairo, libxcb, seatd
, libXcursor, xlibsWrapper, udev, libdrm, mtdev, libjpeg, pam, dbus, libinput, libevdev, pixman
, colord, lcms2, pipewire ? null
, pango ? null, libunwind ? null, freerdp ? null, vaapi ? null, libva ? null
, libwebp ? null, xwayland ? null, wayland-protocols
# beware of null defaults, as the parameters *are* supplied by callPackage by default
}:
with lib;
stdenv.mkDerivation rec {
pname = "weston";
version = "10.0.0";
src = fetchurl {
url = "https://wayland.freedesktop.org/releases/${pname}-${version}.tar.xz";
sha256 = "1bj7wnadr7ssn6xw7k8ki0wpj6np3kjd2pcysfz3h0mr290rc8sw";
};
nativeBuildInputs = [ meson ninja pkg-config /* wayland-scanner */ python3 ];
buildInputs = [
wayland libGL mesa libxkbcommon cairo /* libxcb libXcursor xlibsWrapper udev */ libdrm
/* mtdev libjpeg pam dbus */ libinput libevdev /* pango libunwind freerdp vaapi libva */ pixman
/* libwebp */ wayland-protocols
# colord lcms2 pipewire
];
mesonFlags = [
"-Dimage-jpeg=false"
"-Dimage-webp=false"
"-Dlauncher-logind=false"
# "-Dlauncher-libseat=true"
# "-Drenderer-gl=false"
"-Dbackend-drm-screencast-vaapi=false"
# "-Dbackend-drm=false"
"-Dbackend-default=drm"
"-Dbackend-rdp=false"
"-Dxwayland=false"
"-Dcolor-management-lcms=false"
"-Dcolor-management-colord=false"
"-Dremoting=false"
"-Dpipewire=false"
"-Dsimple-clients="
"-Ddemo-clients=false"
"-Dtest-junit-xml=false"
"-Dsystemd=false"
"-Dlauncher-logind=false"
];
# mesonFlags= [
# "-Dbackend-drm-screencast-vaapi=${boolToString (vaapi != null)}"
# "-Dbackend-rdp=${boolToString (freerdp != null)}"
# "-Dxwayland=${boolToString (xwayland != null)}" # Default is true!
# "-Dremoting=false" # TODO
# "-Dpipewire=${boolToString (pipewire != null)}"
# "-Dimage-webp=${boolToString (libwebp != null)}"
# "-Ddemo-clients=false"
# "-Dsimple-clients="
# "-Dtest-junit-xml=false"
# # TODO:
# #"--enable-clients"
# #"--disable-setuid-install" # prevent install target to chown root weston-launch, which fails
# ] ++ optionals (xwayland != null) [
# "-Dxwayland-path=${xwayland.out}/bin/Xwayland"
# ];
passthru.providedSessions = [ "weston" ];
meta = {
description = "A lightweight and functional Wayland compositor";
longDescription = ''
Weston is the reference implementation of a Wayland compositor, as well
as a useful environment in and of itself.
Out of the box, Weston provides a very basic desktop, or a full-featured
environment for non-desktop uses such as automotive, embedded, in-flight,
industrial, kiosks, set-top boxes and TVs. It also provides a library
allowing other projects to build their own full-featured environments on
top of Weston's core. A small suite of example or demo clients are also
provided.
'';
homepage = "https://gitlab.freedesktop.org/wayland/weston";
license = licenses.mit; # Expat version
platforms = platforms.linux;
maintainers = with maintainers; [ primeos ];
};
}
|