-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathCargo.toml
More file actions
209 lines (181 loc) · 6.14 KB
/
Cargo.toml
File metadata and controls
209 lines (181 loc) · 6.14 KB
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
# {{{ Workspace
[workspace]
members = ["fht-compositor-config", "fht-compositor-ipc", "fht-share-picker"]
resolver = "2"
[workspace.package]
version = "25.10.1"
description = "A dynamic tiling Wayland compositor"
authors = ["Nadjib Ferhat <nferhat20@gmail.com>"]
license = "GPL-3.0"
edition = "2021"
repository = "https://github.com/nferhat/fht-compositor"
[workspace.dependencies]
anyhow = "1.0.79"
clap = { version = "4.5.42", features = ["derive", "string"] }
tracing = "0.1.40"
tracing-subscriber = { version = "0.3.18", features = ["env-filter"] }
serde_json = "1.0.134"
serde = { version = "1.0.217", features = ["derive"] }
[workspace.dependencies.smithay]
git = "https://github.com/smithay/Smithay"
rev = "5de53056b5cafd453371af2d4e955931ce87ef71"
default-features = false
[workspace.dependencies.smithay-drm-extras]
git = "https://github.com/Smithay/Smithay"
rev = "5de53056b5cafd453371af2d4e955931ce87ef71"
[profile.opt]
inherits = "release"
codegen-units = 1
lto = "fat"
opt-level = 3
[profile.dev]
opt-level = 3
# }}}
# {{{ fht-compositor
[package]
name = "fht-compositor"
version.workspace = true
description.workspace = true
authors.workspace = true
license.workspace = true
edition.workspace = true
repository.workspace = true
lints.workspace = true
readme = "README.md"
rust-version = "1.85"
[dependencies]
anyhow.workspace = true
tracing.workspace = true
tracing-subscriber.workspace = true
smithay = { workspace = true, features = [
"desktop",
"wayland_frontend", # Provide abstractions for wayland stuff
"renderer_glow", # Default renderer used everywhere
"backend_gbm", # required for pipewire madness
"use_system_lib",
"backend_egl", # EGL support for wayland
"use_system_lib",
"backend_egl", # EGL support for wayland
"backend_gbm", # libgbm, needed for many things
"backend_libinput", # Input handling
] }
calloop = { version = "0.14.3", features = ["executor", "futures-io"] }
smithay-drm-extras = { workspace = true, optional = true }
bitflags = "2.9.1"
thiserror = "2.0.12"
libc = "0.2.155"
zbus = { version = "5.5.0", optional = true }
zvariant = { version = "5.4.0", features = [
"option-as-array",
], optional = true }
xcursor = "0.3.5"
fht-compositor-config.path = "./fht-compositor-config"
glam = "0.30.5"
egui = "0.32"
egui_glow = "0.32"
serde.workspace = true
serde_json.workspace = true
fht-compositor-ipc = { path = "./fht-compositor-ipc", features = ["clap"] }
fht-animation = { git = "https://github.com/nferhat/fht-animation", version = "0.1.0" }
# FIXME: We use this instead of std::sync::MappedMutexGuard
# SEE: tracking issue for nightly flag: https://github.com/rust-lang/rust/issues/117108
safer_owning_ref = "0.5.0"
async-channel = "2.3.1"
async-io = "2.3.4"
clap.workspace = true
clap_complete = "4.5.38"
xdg = "3.0.0"
tracy-client = { version = "0.18.0", default-features = false }
serde_repr = "0.1.20"
libdisplay-info = "0.3.0"
drm-ffi = "0.9.0"
sd-notify = { version = "0.4.5", optional = true }
futures-util = { version = "0.3.31", features = ["std", "io"] }
wayland-scanner = "0.31.7"
[dependencies.pipewire]
git = "https://gitlab.freedesktop.org/pipewire/pipewire-rs.git"
rev = "8248451f82cb2b886ea9762917ae4baade4e164b"
optional = true
features = ["v0_3_33" ]
[features]
default = ["winit-backend", "udev-backend", "headless-backend", "all-portals"]
# Marker feature to enable D-Bus connectivity.
#
# You should not enable this yourself, this is meant to be used by compositor
# feature dependencies.
dbus = ["zbus", "zvariant"]
# Enable the winit backend.
#
# This allows the compositor to run under a winit window.
#
# NOTE: Although this backend works, it's not explicity supported, since its only here for
# developement. For all regular usage, please use the udev backend.
winit-backend = [
"smithay/backend_winit",
"smithay/renderer_glow",
"smithay/backend_drm",
]
# Enable the winit backend.
#
# This allows the compositor to run under a libseat session.
udev-backend = [
"smithay-drm-extras",
"smithay/backend_libinput",
"smithay/backend_udev",
"smithay/backend_drm",
"smithay/backend_gbm",
"smithay/backend_vulkan",
"smithay/backend_egl",
"smithay/backend_session_libseat",
"smithay/renderer_multi",
]
# A headless backend.
# ---
# This backend is for pure testing purposes. You are not expected to use this nor to compile this.
# It's used when testing the IPC and stuff that doesn't require a graphical instance running
headless-backend = []
# Enable profiling with tracy
#
# You should **NOT** enable this unless you want to profile compositor performance.
# This will automatically stream compositor data to localhost:DEFAULT_PORT.
profile-with-tracy = ["tracy-client/default"]
profile-with-tracy-allocations = ["profile-with-tracy"]
# Marker feature to enable all supported portals.
all-portals = ["xdg-screencast-portal"]
# Enable xdg-screencast portal support
xdg-screencast-portal = ["pipewire", "dbus", "smithay/backend_gbm", "fht-compositor-ipc/screencast-source"]
# Enable integration with systemd.
systemd = ["dep:sd-notify", "dbus"]
# }}}
# {{{ Lints
# For the sake of code correctness, we force quite aggressive lints.
#
# In the past I used to program without much though about this, but having lints to guide
# your coding habits is quite necessary for such a large project.
[workspace.lints.rust]
rust_2018_idioms = { level = "deny", priority = -1 }
missing_debug_implementations = "deny"
mismatched_lifetime_syntaxes = "allow"
[workspace.lints.clippy]
pedantic = { level = "forbid", priority = -1 }
ignored-unit-patterns = "allow"
module-name-repetitions = "allow"
too-many-lines = "allow"
too-many-arguments = "allow"
type-complexity = "allow"
semicolon-if-nothing-returned = "deny"
trivially-copy-pass-by-ref = "deny"
default-trait-access = "deny"
match-wildcard-for-single-variants = "deny"
redundant-closure-for-method-calls = "deny"
filter-map-next = "deny"
manual-let-else = "deny"
unused-async = "deny"
from-over-into = "allow"
needless-borrow = "deny"
new-without-default = "deny"
useless-conversion = "deny"
redundant-static-lifetimes = "allow"
missing-transmute-annotations = "allow" # we always do implicit transmutes
# }}}
# vim: foldmethod=marker