Avatar ·

How to specify only binary dependencies (without sources) in Cargo for Rust?

Hi everyone! I'm new to Rust and trying to figure out the Cargo build system. I have a project that uses an external library that provides only a compiled binary file (e.g., `.so` or `.dll`). The source code for this library is not available — it's a proprietary SDK. In my `Cargo.toml`, I specified the dependency via `path`: ```toml [dependencies] my_sdk = { path = "/opt/vendor/sdk" } ``` But Cargo throws an error that it cannot find `Cargo.toml` in the specified folder. I tried using `git` and `crates.io`, but this library is not there. How do I correctly tell Cargo that the dependency is an already compiled binary and sources are not needed? Maybe there is some attribute like `bin-only` or `prebuilt`? I'm using Rust 1.70.0 on Ubuntu. I would appreciate any examples.