web browser (Servo)
git clone https://git.lucas.co/cce-browser.git
Cargo.toml (3.3K)
1 [package]
2 name = "cce-browser"
3 version = "0.1.0"
4 edition = "2021"
5 # Only runs bindgen when the `wpe` feature is on, so a default build needs
6 # no WPE headers and stays exactly as it was.
7 build = "build.rs"
8
9 [features]
10 # WPE WebKit is the engine as of 2026-08-30 (see WPE-PORT.md). Default, so a
11 # plain `cargo build` — including another session's sweep or reinstall —
12 # ships the right engine instead of silently reverting to Servo, which is
13 # exactly what happened two days after the port landed. Needs
14 # `pacman -S wpewebkit`.
15 default = ["wpe"]
16 wpe = ["dep:rustix"]
17 # The retired Servo backend, kept buildable for comparison:
18 # cargo build --release -p cce-browser --no-default-features --features servo
19 servo = ["dep:servo", "dep:dpi", "dep:euclid", "dep:rustls", "dep:reqwest", "dep:http"]
20
21 [dependencies]
22 cce-ui = { git = "https://github.com/lsgalante/cce-ui.git", rev = "f3c970be244ad54121021a8223986ba553e09838" }
23 calloop = "0.13.0"
24 wayland-client = { version = "0.31", features = ["system"] }
25 servo = { version = "0.4", optional = true }
26 url = "2"
27 http = { version = "1", optional = true }
28 reqwest = { version = "0.12", features = ["blocking"], optional = true }
29 dpi = { version = "0.1", optional = true }
30 euclid = { version = "0.22", optional = true }
31 rustls = { version = "0.23", features = ["aws-lc-rs"], optional = true }
32 log = "0.4"
33 env_logger = "0.11"
34 # Accounts from cce-secrets: the same Secret Service store cce-secrets
35 # fronts (gnome-keyring here), read over D-Bus. The *blocking* API on a
36 # worker thread, deliberately — an unlock prompt can block for as long as it
37 # takes and must never be on the frame path — so no async runtime is pulled
38 # into the browser: async-io, not tokio.
39 secret-service = { version = "5", features = ["rt-async-io-crypto-rust"] }
40 # The account watcher's page messages are JSON, and cce-ui parses config
41 # through serde_json already — this only names the parser directly.
42 serde_json = "1"
43 # Naming a Secret Service object path (the handle a picked account's secret is
44 # fetched by). Already in the tree under secret-service; this only names it.
45 zbus = "5"
46 # Only used by the `wpe` backend, to hold GLib's changing pollfd set in one
47 # epoll fd that calloop can watch. Optional so a default build skips it.
48 rustix = { version = "0.38", features = ["event"], optional = true }
49
50 [build-dependencies]
51 bindgen = "0.72"
52 pkg-config = "0.3"
53
54 # The desktop entry's Exec target: a forwarder that links (almost) nothing,
55 # so the click-to-tab path skips the ~20ms of library loading the full
56 # binary pays before main(). Explicit [[bin]] only for the name — src/bin/
57 # autodiscovery would call it `open`. ccebuild installs it automatically
58 # via cargo metadata; no Makefile involvement.
59 [[bin]]
60 name = "cce-browser-open"
61 path = "src/bin/open.rs"
62
63 # The WPE examples need the generated bindings, so they only build with
64 # the feature — otherwise `cargo test` would try them on a default build.
65
66 [[example]]
67 name = "wpe_spike"
68 required-features = ["wpe"]
69
70 [[example]]
71 name = "wpe_host"
72 required-features = ["wpe"]
73
74 [[example]]
75 name = "wpe_input"
76 required-features = ["wpe"]
77
78 [[example]]
79 name = "wpe_loop"
80 required-features = ["wpe"]
81
82 [[example]]
83 name = "wpe_tabs"
84 required-features = ["wpe"]
85
86 [[example]]
87 name = "wpe_dark"
88 required-features = ["wpe"]
89
90 [[example]]
91 name = "wpe_paste"
92 required-features = ["wpe"]
93
94 [[example]]
95 name = "wpe_ctx"
96 required-features = ["wpe"]