-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathCargo.toml
More file actions
188 lines (161 loc) · 8.34 KB
/
Copy pathCargo.toml
File metadata and controls
188 lines (161 loc) · 8.34 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
[workspace]
members = ["android/rust", "ios/rust"]
[package]
name = "vellum-fe"
version = "0.3.0-beta.46"
edition = "2021"
authors = ["Nisugi"]
description = "Modern, high-performance multi-frontend (TUI/GUI) client for GemStone IV"
license = "GPL-3.0-or-later"
repository = "https://github.com/Nisugi/VellumFE"
[[bin]]
name = "vellum-fe"
path = "src/main.rs"
# The desktop binary always ships both frontends; the feature split exists so
# the library builds with --no-default-features for Android (headless + web).
required-features = ["tui", "gui", "desktop"]
[dependencies]
# Core async runtime
tokio = { version = "1", features = ["full"] }
anyhow = "1"
# Terminal UI
ratatui = { version = "0.29", optional = true }
# Nisugi fork of justinpopa's keypad-aware fork; same content today, ours so
# phase-2 work (Windows VT input for numpad under Alacritty/ConPTY) has a home.
crossterm = { git = "https://github.com/Nisugi/crossterm.git", branch = "dev", features = ["event-stream"], optional = true }
tui-textarea = { version = "0.7", optional = true }
unicode-segmentation = { version = "1", optional = true }
# GUI (numpad-aware fork)
egui = { git = "https://github.com/Nisugi/egui.git", branch = "numpad-support", package = "egui", optional = true, features = ["callstack"] }
eframe = { git = "https://github.com/Nisugi/egui.git", branch = "numpad-support", package = "eframe", default-features = false, features = ["default_fonts", "wgpu", "x11", "wayland"], optional = true }
fontdb = { version = "0.23", optional = true } # System font discovery for per-window font selection
skrifa = { version = "0.42", default-features = false, features = ["std"], optional = true } # Same parser epaint uses; pre-validate picked fonts (epaint panics on unparseable font data)
image = { version = "0.25", default-features = false, features = ["png", "jpeg", "webp", "bmp", "gif"], optional = true } # Skin image decoding (backgrounds, icons) + custom-emoji GIF animation frames
# Serialization
serde = { version = "1", features = ["derive", "rc"] }
serde_json = "1"
toml = "0.8"
toml_edit = "0.22" # Comment-preserving config + skin.toml edits (sparse saves, calibrator)
dirs = "5"
# Text processing
regex = "1"
fancy-regex = "0.14" # Lookaround support for Ruby-authored gameobj-data regexes
aho-corasick = "1" # Fast literal string matching for highlights
emojis = "0.9.0" # Embedded gemoji data for :grin:-style shortcode expansion
quick-xml = "0.36" # XML parsing
include_dir = "0.7" # Embed default config files
rpassword = { version = "7", optional = true }
# eAccess login TLS via the OS stack: SChannel (Windows), Security.framework
# (macOS), system OpenSSL (Linux). No vendored OpenSSL build, no Perl, no vcpkg.
# NOTE: rustls cannot replace this — eaccess.play.net only speaks TLS 1.2 with
# static-RSA key exchange (AES128-GCM-SHA256), which rustls refuses to implement.
native-tls = "0.2"
getrandom = "0.3" # Web pairing token generation
# Seals stored passwords on non-desktop builds (Android): the key comes
# from the Kotlin shell via VELLUM_PASSWORD_KEY (Android Keystore wraps
# it at rest). Pure Rust, compiled everywhere, used only without the
# `desktop` feature (desktop uses the OS keyring instead).
chacha20poly1305 = "0.10"
# SSH client for the launcher: cold-start a headless Lich session on a home
# PC over an existing WireGuard/Tailscale tunnel, then attach to it. We select
# the `ring` crypto backend and drop russh's default `aws-lc-rs` — aws-lc-rs
# pulls aws-lc-sys, a C/CMake build that is painful to cross-compile for
# iOS/Android; ring is prebuilt-friendly and the mobile builds already share
# the ring lineage. `flate2` keeps SSH compression; `rsa` is dropped because
# our launcher key is ed25519 (server host keys we accept can still be RSA —
# ring verifies those without the `rsa` signing feature).
russh = { version = "0.62", default-features = false, features = ["ring", "flate2"] }
# ed25519 keypair generation for the launcher key. russh's own key-gen path
# uses rand 0.10's rng(); we match it so PrivateKey::random accepts our RNG.
rand = "0.10"
# Mapdb release downloads (GitHub releases API + asset fetch). Blocking on
# purpose — it runs on the mapdb-update worker thread. Rides the same
# native-tls stack as eAccess login; no rustls, no second TLS stack.
ureq = { version = "2", default-features = false, features = ["native-tls", "gzip"] }
# Cartographer stringprocs.tar.gz extraction (proc bodies sidecar).
flate2 = "1"
tar = "0.4"
# Web server (mobile web frontend) - HTTP + WebSocket sidecar
axum = { version = "0.8", features = ["ws"] }
# WebSocket client for the Lich WebUI bridge (loopback only, no TLS)
tokio-tungstenite = "0.26"
futures-util = { version = "0.3", default-features = false, features = ["sink"] }
qrcode = { version = "0.14", default-features = false, features = ["svg"] } # .webinfo pairing QR
# Shareable UI packs (.uiexport / .uiimport): zip with the config files
# + skin assets that make a UI. Deflate only — no extra codecs.
zip = { version = "2", default-features = false, features = ["deflate"] }
# Sound (optional)
rodio = { version = "0.19", optional = true }
# Gamepad input for the GUI (Windows WGI, Linux evdev, macOS IOKit).
# Desktop-only: the mobile builds get controllers via the browser Gamepad API.
gilrs = { version = "0.11", optional = true }
# TTS - Text-to-speech (feature-gated; stub on non-desktop builds)
tts = { version = "0.26", optional = true }
# Logging
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
tracing-appender = "0.2"
# CLI
clap = { version = "4", features = ["derive"] }
# Time handling
chrono = "0.4"
# Clipboard
arboard = { version = "3", optional = true }
base64 = "0.22.1"
# SHA1 for the asset-manager (jinx) digest: repositories publish
# base64(SHA1(bytes)) per asset (Jinx calls the field "md5"); we recompute
# and compare byte-for-byte with Ruby's Digest::SHA1.base64digest. Already
# in the lock via tokio-tungstenite's handshake — pinned here for direct use.
sha1 = "0.10"
sysinfo = { version = "0.30", optional = true }
# URL opening (for LaunchURL)
open = { version = "5", optional = true }
# OS credential store for launcher profiles (Windows Credential Manager /
# macOS Keychain / Linux Secret Service). Best-effort: launcher falls back
# to prompting when no secure store is available (headless, WSL, bare WMs).
keyring = { version = "3", features = ["windows-native", "apple-native", "sync-secret-service", "vendored"], optional = true }
[features]
# The Android build is `--no-default-features`: core + parser + network +
# web frontend + (Phase A2) headless runtime only.
default = ["tui", "gui", "sound", "tts", "desktop", "gamepad"]
tui = ["dep:ratatui", "dep:crossterm", "dep:tui-textarea", "dep:unicode-segmentation"]
gui = ["dep:egui", "dep:eframe", "dep:fontdb", "dep:skrifa", "dep:image"]
gamepad = ["dep:gilrs"]
sound = ["dep:rodio"]
tts = ["dep:tts"]
# Desktop OS integrations: clipboard, browser-open, process inspection,
# credential store, terminal password prompt.
desktop = ["dep:arboard", "dep:open", "dep:sysinfo", "dep:keyring", "dep:rpassword"]
# Linux/Android: statically link a vendored OpenSSL so binaries don't depend
# on the system libssl (Android has none). Perl is needed to build it, but
# it's universal on Linux and present on CI runners; the vendored-build pain
# the native-tls swap removed was Windows-only.
[target.'cfg(any(target_os = "linux", target_os = "android"))'.dependencies]
native-tls = { version = "0.2", features = ["vendored"] }
# Platform-specific dependencies for window position persistence
[target.'cfg(windows)'.dependencies]
windows = { version = "0.58", features = [
"Win32_Foundation",
"Win32_System_Console",
"Win32_System_Threading",
"Win32_System_Diagnostics_ToolHelp",
"Win32_UI_WindowsAndMessaging",
"Win32_Graphics_Gdi",
"Win32_Storage_FileSystem",
"Win32_Security",
]}
# Optimize dependencies even in dev builds: our code stays opt-level 0 for
# fast incremental compiles and clean debugging, but egui rendering and PNG
# decoding (skin loads froze the debug build for ~15s unoptimized) run at
# near-release speed.
[profile.dev.package."*"]
opt-level = 2
[profile.release]
opt-level = 3
lto = true
codegen-units = 1
[dev-dependencies]
tempfile = "3.24.0"
[patch.crates-io]
egui = { git = "https://github.com/Nisugi/egui.git", branch = "numpad-support", package = "egui" }
gpu-allocator = { path = "vendor/gpu-allocator-0.28.0" }