-
Notifications
You must be signed in to change notification settings - Fork 10
/
Cargo.toml
162 lines (136 loc) · 4.69 KB
/
Cargo.toml
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
[package]
name = "hid-io-core"
version = "0.1.4"
authors = ["Jacob Alexander <haata@kiibohd.com>"]
license = "GPL-3.0-or-later"
description = """
HID-IO is a host-side daemon for advanced HID devices.
"""
homepage = "https://github.com/hid-io/hid-io-core"
repository = "https://github.com/hid-io/hid-io-core"
edition = "2021"
build = "build.rs"
default-run = "hid-io-core"
[workspace]
members = [
"hid-io-client",
"hid-io-protocol",
]
[features]
default = ["api", "dev-capture", "displayserver", "hidapi-devices", "vhid"]
# api handles socket interfaces for HID-IO
# e.g. capnproto interface
# Disabling will reduce compile times
api = [
"capnp",
"capnpc",
"capnp-rpc",
"futures",
"futures-util",
"glob",
"nanoid",
"rcgen",
"tempfile",
"tokio-rustls",
"tokio-stream",
"tokio-util",
]
# dev_capture handles any HID event capturing for standard input devices
# Disabling will reduce compile times
dev-capture = [
"evdev-rs",
"libc",
"nanoid",
"udev",
]
# displayserver interacts with the OS display server (e.g. winapi, quartz, x11, wayland)
# Disabling will reduce compile times
displayserver = [
"core-foundation",
"core-graphics",
"memmap2",
"tempfile",
"wayland-client",
"wayland-protocols-misc",
"winapi",
"winreg",
"x11",
"xkbcommon",
]
# hidapi_devices allows for communication directly with hid-io supported devices
# This should be enabled in most scenarios unless you know what you are doing.
# Disabling will reduce compile times
hidapi-devices = [
"hidapi",
"regex",
"tokio-stream",
]
# vhid (virtual hid) allows for the creation of virtual hid devices.
# This is needed to support virtual devices such as virtual joysticks, mice and keyboards
# Disabling will reduce compile times
vhid = [
"libc",
"nanoid",
"udev",
"uhid-virt",
]
[build-dependencies]
built = { version = "0.6", features = ["git2", "chrono"] }
capnpc = { version = "0.14", optional = true }
rustc_version = "0.2"
[dependencies]
capnp = { version = "0.14", optional = true }
capnp-rpc = { version = "0.14", optional = true }
clap = "3.1"
ctrlc = "3.2"
lazy_static = "1.4"
flexi_logger = { version = "0.25" }
futures = { version = "0.3", optional = true }
futures-util = { version = "0.3", optional = true }
glob = { version = "0.3", optional = true }
heapless = { version = "0.7" }
hidapi = { version = "2.3.3", default-features = false, features = ["linux-native"], optional = true }
hid-io-protocol = { path = "hid-io-protocol", version = "^0.1.6" }
libc = { version = "0.2", optional = true }
log = "0.4"
nanoid = { version = "0.4", optional = true }
open = "3.0"
rcgen = { version = "0.11", optional = true }
regex = { version = "1.8", optional = true }
sys-info = "0.9"
tempfile = { version = "3.6", optional = true }
tokio = { version = "1.18", features = ["net", "rt-multi-thread", "macros", "sync", "time"] }
tokio-rustls = { version = "0.23", optional = true }
tokio-stream = { version = "0.1", features = ["sync"], optional = true }
tokio-util = { version = "0.7", optional = true, features = ["compat"] }
[dev-dependencies]
rand = "0.8"
webpki = "0.22"
[dev-dependencies.cargo-husky]
version = "1"
features = ["prepush-hook", "run-cargo-fmt", "run-cargo-clippy", "run-cargo-test"]
[package.metadata.cargo-udeps.ignore]
development = ["cargo-husky"]
[target.'cfg(target_os = "linux")'.dependencies]
evdev-rs = { version = "0.5", optional = true }
memmap2 = { version = "^0.5", optional = true }
udev = { version = "^0.6", optional = true }
uhid-virt = { version = "0.0.6", optional = true }
wayland-client = { version = "0.30.0-beta.13", optional = true }
wayland-protocols-misc = { version = "0.1.0-beta.13", optional = true, features = ["client"] }
xkbcommon = { version = "^0.5.0-beta", optional = true, features = ["x11"] }
x11 = { version = "^2.19", optional = true }
[target.'cfg(windows)'.dependencies]
winapi = { version = "0.3", optional = true, features = ["std", "winuser", "winnls"] }
winreg = { version = "0.10", optional = true }
windows-service = "0.5"
[target.'cfg(target_os = "macos")'.dependencies]
core-foundation = { version = "0.9", optional = true }
core-graphics = { version = "0.22", optional = true }
[package.metadata.bundle]
identifier = "io.github.hid-io.hid-io-core"
category = "public.app-category.utilities"
icon = ["128x128.png"]
resources = ["hid-io-core.service"]
[profile.release]
panic = "abort" #windows