-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
windows: libwebrtc-sys conflicts with other crates that use C/C++ #364
Comments
13 tasks
SomeoneToIgnore
added a commit
to zed-industries/zed
that referenced
this issue
Nov 15, 2024
See livekit/rust-sdks#355 Todo: * [x] make `call` / `live_kit_client` crates use the livekit rust sdk * [x] create a fake version of livekit rust API for integration tests * [x] capture local audio * [x] play remote audio * [x] capture local video tracks * [x] play remote video tracks * [x] tests passing * bugs * [x] deafening does not work (livekit/rust-sdks#359) * [x] mute and speaking status are not replicated properly: (livekit/rust-sdks#358) * [x] **linux** - crash due to symbol conflict between WebRTC's BoringSSL and libcurl's openssl (livekit/rust-sdks#89) * [x] **linux** - libwebrtc-sys adds undesired dependencies on `libGL` and `libXext` * [x] **windows** - linker error, maybe related to the C++ stdlib (livekit/rust-sdks#364) ``` libwebrtc_sys-54978c6ad5066a35.rlib(video_frame.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in libtree_sitter_yaml-df6b0adf8f009e8f.rlib(2e40c9e35e9506f4-scanner.o) ``` * [x] audio problems Release Notes: - Switch from Swift to Rust LiveKit SDK 🦀 --------- Co-authored-by: Mikayla Maki <mikayla@zed.dev> Co-authored-by: Conrad Irwin <conrad@zed.dev> Co-authored-by: Kirill Bulatov <kirill@zed.dev> Co-authored-by: Michael Sloan <michael@zed.dev>
mgsloan
referenced
this issue
in zed-industries/webrtc
Jan 19, 2025
…rtAsString()` Justification for this change is that `std::to_string` should be avoided as it uses the user's locale and calls to it get serialized, which is bad for concurrency. My actual motivation for this is quite bizarre. Before this change, with Zed's use of the LiveKit Rust SDK, I was getting connection strings that were not valid utf-8, instead having a port of `3\u0000\u0000\u001c\u0000`. I have not figured out how that could happen or why this change fixes it.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It looks like the prebuilt WebRTC library downloaded by the
libwebrtc-sys
build links the windowsC Runtime Library
statically, as opposed to dynamically, which causes linker errors when using other Rust crates that link to the C Runtime Library.When compiling an application that uses both
LiveKit
and other crates that include C code viabuild.rs
and thecc
crate, the Zed project is getting a large number of linker errors like this:Here is the CI build where this error (and many similar ones) occurred.
The error mentions an object file
libtree_sitter_yaml-..-scanner.o
, which is just one of the crates that Zed depends on that uses C++. Here is the build.rs for that crate. You can see it's pretty standard - just including some C code via thecc
crate.The text was updated successfully, but these errors were encountered: