Cargo patch not working

I have a project that uses glutin. Glutin uses winit internally, but I'd like to use tao instead. This seems like a job for patch, but it's not working. Here's my Cargo.toml:

name = "cargo_please"
version = "0.1.0"
edition = "2021"

glutin = "0.28.0"

winit = { git = "", package = "tao" }

And cargo build output:

warning: Patch `tao v0.5.2 (` was not used in the crate graph.
Check that the patched package version and available features are compatible
with the dependency requirements. If the patch has a different version from
what is locked in the Cargo.lock file, run `cargo update` to use the new
version. This may also occur with an optional dependency that is not enabled.
    Finished dev [unoptimized + debuginfo] target(s) in 0.03s

I ran cargo update and it didn't help. Can someone help me understand the problem?

The problem is that tao has a different version from the winit version that glutin expects.

There’s no way to solve this without forking glutin or tao, according to the discussion in #5640.

Thanks for the answer. That's unfortunate; looks like we'll have to maintain a fork :frowning:

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.