nandi/jolt-nativepublic Fork 0
aabacba05769796ca2b8dde03e3f925d33ba6653
Commits
Clone
git clone https://git.rickub.com/nandi/jolt-native.git
git clone ssh://git@rickub.com/nandi/jolt-native.git

Host key fingerprint (ed25519): SHA256:iycHnxEyq0Q7uyVpB7JlznP0G7JrTPXLYRcAU5CSLhc — verify it before your first connect.

Cargo.toml · 132 lines · 6.7 KBTOML Blame HistoryRaw
Build under buck2, with the toolchain pinned rather than found 460541b nandi 19d ago1# The third-party graph, as one manifest for reindeer to vendor and generate
2# BUCK targets from. Every external crate the workspace's four members depend
3# on appears here once, with the union of the features they ask for; first-party
4# crates keep their own BUCK files and depend on `//third-party/rust:<name>`.
5#
Give the third-party crates a platform to be Android on 0238622 nandi 19d ago6# Android-only dependencies are at the bottom, in a target section, so their
7# features are resolved for the device and unified into nothing else.
Build under buck2, with the toolchain pinned rather than found 460541b nandi 19d ago8[package]
9name = "jolt-native-third-party"
10version = "0.0.0"
11edition = "2021"
12publish = false
13
14# Its own workspace: reindeer resolves this graph on its own, and the root
15# workspace must not try to make it a member.
16[workspace]
17
18# Nothing is compiled from here; the manifest exists to pin a graph.
19[lib]
20path = "lib.rs"
21
22[dependencies]
23anyhow = "1"
24# cpal's cross-platform sample trait; see the note above the patch table.
25dasp_sample = "0.11"
26# `image-data` is the clipboard path for a pasted picture; egui does not deliver
27# one. Desktop only — arboard has no Android backend.
28arboard = { version = "3", default-features = false, features = ["image-data"] }
29# Without cpal's `pipewire` feature, which is on by default under cargo: it
30# builds libspa-sys, which wants pkg-config and PipeWire's headers on the build
31# machine — the one system dependency the zig toolchain cannot stand in for.
32# The buck2 build is therefore `--no-default-features` shaped for now: ALSA PCM
33# names only, everything else equal.
34cpal = { path = "cpal" }
35# `default_fonts` because a shared library has no host app to install a font set
36# for it. vidya-core turns egui's defaults off; the union is what gets built.
37egui = { version = "0.31", features = ["default_fonts"] }
38egui-winit = "0.31"
39egui_glow = "0.31"
40env_logger = "0.11"
41glow = "0.16"
42glutin = "0.32"
43glutin-winit = "0.5"
44# JPEG only — the V4L2 path converts MJPEG frames, and nothing here reads or
45# writes a picture file.
46image = { version = "0.25", default-features = false, features = ["jpeg"] }
47iroh-live = { git = "https://github.com/n0-computer/iroh-live", rev = "edd9bcc530a615f3ab3a6919e96790a077905376", default-features = false, features = [
48 "opus",
49 "h264",
50 "capture-camera",
51] }
52libc = "0.2"
53log = "0.4"
54moq-lite = { git = "https://github.com/Frando/moq", branch = "deps/iroh-main" }
55moq-native = { git = "https://github.com/Frando/moq", branch = "deps/iroh-main", default-features = false, features = [
56 "noq",
57 "websocket",
58 "aws-lc-rs",
59] }
60mp4 = "0.14"
61n0-future = "0.3"
62# C++, which is why the toolchain needs both halves of zig.
63openh264 = { version = "0.9", default-features = false, features = ["source"] }
64png = "0.17"
65rand = "0.8"
66# aws-lc-rs rather than ring, to match what moq-native and iroh already pull in.
67rustls = { version = "0.23", default-features = false, features = ["aws-lc-rs"] }
68tokio = { version = "1", features = ["rt-multi-thread", "macros", "sync", "time"] }
69# One query parameter (`inst=`) needs escaping. That is the whole use.
70urlencoding = "2"
71url = "2"
72# V4L2 capture: the fallback path for cameras rusty-capture mishandles.
73v4l2r = "0.0.7"
74winit = "0.30"
75zip = { version = "2", default-features = false, features = ["deflate"] }
76
77# Carried over from the workspace root verbatim: iroh-live wants an unreleased
78# iroh 0.97, and the revs are the ones freeq locks. They travel together and are
79# not independently bumpable.
80# cpal's own dependencies, named here so reindeer gives them public aliases:
81# the hand-written target in cpal/BUCK lives in a different package, and
82# reindeer only makes top-level deps visible outside its own.
83[target.'cfg(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd", target_os = "netbsd"))'.dependencies]
84alsa = "0.11"
85
86[target.'cfg(target_vendor = "apple")'.dependencies]
87coreaudio-rs = { version = "0.14", default-features = false, features = ["core_audio", "audio_toolbox"] }
88mach2 = "0.5"
89objc2 = "0.6"
90objc2-audio-toolbox = { version = "0.3", default-features = false, features = ["std", "AUComponent", "AudioUnitProperties"] }
91objc2-core-audio = { version = "0.3", default-features = false, features = ["std", "AudioHardware", "AudioHardwareDeprecated", "objc2", "objc2-foundation"] }
92objc2-core-audio-types = { version = "0.3", default-features = false, features = ["std", "CoreAudioBaseTypes"] }
93objc2-core-foundation = "0.3"
94objc2-foundation = "0.3"
95
Give the third-party crates a platform to be Android on 0238622 nandi 19d ago96# The device. libjoltmoq does not cross — the media plane is V4L2 and PipeWire —
97# so this is libvidya's half of the graph and nothing else.
98[target.'cfg(target_os = "android")'.dependencies]
99# `vidya_open_url` is an ACTION_VIEW intent there, which is a JNI call against
100# the activity the glue holds.
101#
102# Renamed because cpal wants jni 0.21 on the same platform, and cpal is a path
103# dependency above — so reindeer gives its deps public aliases too, and two
104# crates called `jni` cannot both have one. The consumer says `named_deps`.
105jni-0-22 = { package = "jni", version = "0.22" }
106# The feature is what pulls in android-activity, and android-activity is what
107# owns the event loop: the APK's NativeActivity has no Java main to call into,
108# so the glue is the entry point. Without it the crate compiles to a backend of
109# no platform at all and fails on its own imports.
110winit = { version = "0.30", features = ["android-native-activity"] }
111
Build under buck2, with the toolchain pinned rather than found 460541b nandi 19d ago112[patch.crates-io]
113iroh = { git = "https://github.com/n0-computer/iroh", rev = "8af8370b" }
114iroh-base = { git = "https://github.com/n0-computer/iroh", rev = "8af8370b" }
115iroh-relay = { git = "https://github.com/n0-computer/iroh", rev = "8af8370b" }
116iroh-gossip = { git = "https://github.com/n0-computer/iroh-gossip", rev = "1038f721" }
117noq = { git = "https://github.com/n0-computer/noq", rev = "ab042ea7e3f7bae1e43eaba2ac9dba47ddb52e69" }
118noq-proto = { git = "https://github.com/n0-computer/noq", rev = "ab042ea7e3f7bae1e43eaba2ac9dba47ddb52e69" }
119noq-udp = { git = "https://github.com/n0-computer/noq", rev = "ab042ea7e3f7bae1e43eaba2ac9dba47ddb52e69" }
120web-transport-iroh = { git = "https://github.com/Frando/web-transport", rev = "f7a523f1" }
121web-transport-noq = { git = "https://github.com/Frando/web-transport", rev = "f7a523f1" }
122web-transport-proto = { git = "https://github.com/Frando/web-transport", rev = "f7a523f1" }
123web-transport-trait = { git = "https://github.com/Frando/web-transport", rev = "f7a523f1" }
124
125# moq-media (inside iroh-live) asks for cpal on `branch = "master"`, which
126# floats, and master no longer compiles against the iroh-live rev pinned above.
127# The vendored copy is the last commit that does — 63ea9ff upstream, per its
128# .cargo_vcs_info.json. It has to be a path rather than that rev: cargo
129# canonicalises the URL, so naming the same repo without `.git` is still "the
130# same source", which a patch may not retarget.
131[patch."https://github.com/RustAudio/cpal.git"]
132cpal = { path = "cpal" }