Builds out the full v1 scope: a vendored+patched openscreen subset for low-latency Cast Streaming (Mirroring receiver 0F5096E8) alongside the existing Cast V2/HLS and new DLNA/AVTransport casting paths, breadcastd's Idle/Casting state machine with a private IPC socket, the breadcast GTK4 popup as a thin IPC client, and bread.cast.*/bread.command.cast.* breadd integration (device discovery, start/stop, mirroring lifecycle events). Also adds bakery/systemd/Forgejo CI packaging. Validated end-to-end against a real Chromecast/Google TV: negotiated Cast Streaming session, live pipeline playback, and daemon+GUI click-to-cast/ stop through the actual popup.
3.5 KiB
Vendoring notes
This directory is a pruned subset of chromium/openscreen,
pinned at the commit in PINNED_COMMIT, licensed BSD-3-Clause (see LICENSE).
It contains only the files needed for the Cast Streaming sender data path
(RTP/RTCP send, OFFER/ANSWER message types, AES frame encryption) plus the
POSIX platform/util plumbing that path needs — not the receiver, not OSP
discovery, not remoting/RPC, not TLS (breadcast's TLS CASTV2 control channel
is handled by the existing rust_cast-based Rust code; this vendored code
only drives the UDP RTP/RTCP data path once rust_cast has already
negotiated OFFER/ANSWER and we know where to send packets).
It is compiled directly via the cc crate in ../build.rs, not GN/Ninja —
there is no build system here to regenerate anything from.
Rolling the pin
There are no release/API-stability guarantees upstream. To update:
- Re-run the file selection against the new commit's
cast/streaming/BUILD.gn(:common+:sendertargets, minuspublic/sender_session.*andpublic/rpc_messenger.*— see "What's excluded" below) plusplatform/BUILD.gn's:base/:api/:standalone_impltargets. - Re-apply the patches below (they're small; check if upstream has since fixed the same problem and the patch can be dropped).
- Update
PINNED_COMMITand rebuild.
What's excluded and why
public/sender_session.{h,cc},public/rpc_messenger.{h,cc},public/receiver_session.*, receiver-side files,remoting.proto/input.proto—SenderSessionbundles mirroring negotiation together with RPC/remoting/input support, which pulls in protobuf (input.pb.h/remoting.pb.h) for no benefit here (breadcast only ever does one-way video mirroring). Instead,../src/session.ccdrivesOffer/Answer/SessionConfigdirectly — logic adapted fromsender_session.cc'sCreateMirroringOffer/StartNegotiation/SelectSenders, minus everything RPC/remoting/audio/input-related.- All TLS support (
platform/impl/tls_*,platform/impl/stream_socket*) — unused; see above. util/crypto/{certificate_utils,digest_sign,pem_helpers,rsa_private_key, secure_hash,sha2}.*— only needed for OSP discovery / X.509 certificate handling, not the RTP data path.util/scoped_wake_lock_mac.cc— macOS-only.
Local patches (not upstream)
build/build_config.h,build/buildflag.h— stand-ins for Chromium's GN-generated versions of these headers. Only define what the 3 callers here actually check (IS_POSIX,IS_LINUX,IS_APPLE,IS_ANDROID), hardcoded for Linux.patches/aes_ctr128_compat.cc—frame_crypto.cccallsAES_ctr128_encrypt(), a BoringSSL convenience wrapper not in system OpenSSL's public headers. Reimplemented from scratch (standard CTR mode overAES_encrypt(), which OpenSSL does still expose).platform/impl/platform_client_posix.{h,cc}— stripped theTlsDataRouterPosixmember/accessor (see "All TLS support" above).util/crypto/openssl_util.{h,cc}— droppedSSLErrorCodeToError()/GetSSLError(), which reference BoringSSL'sSSL_error_description()(not in system OpenSSL). Unused for the same reason as (3).util/base64.cc— upstream implements this onthird_party/modp_b64, which isn't fetched by a plain shallow clone (pulled in separately via gclient/DEPS in a full Chromium checkout). Reimplemented onEVP_EncodeBlock/EVP_DecodeBlockfrom system OpenSSL instead, same public interface.