Skip to content
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

Usage '[patch.*]` report #55

Open
EPashkin opened this issue Sep 12, 2018 · 1 comment
Open

Usage '[patch.*]` report #55

EPashkin opened this issue Sep 12, 2018 · 1 comment

Comments

@EPashkin
Copy link
Member

EPashkin commented Sep 12, 2018

@GuillaumeGomez, @sdroege
I tried use [patch.crates-io] in gtk-rs crates to minimize difference between master and crate branches.
See my test forks https://github.com/EPashkin/examples/tree/as_master,
https://github.com/EPashkin/rust-gnome-sys/tree/as_crate,
https://github.com/EPashkin/glib/tree/as_crate,
https://github.com/EPashkin/cairo/tree/as_crate,
https://github.com/EPashkin/gtk/tree/as_crate
As I used only part crates there there too many [path.*] section in Cargo.toml,
in gtk-rs IMHO it will be only [patch.crates-io].

It works fine until I tried emulate glib version upgrade from 0.6.0 to 0.7.0:
examples tries build both current and next version,
as there already many cons found I stopped checks.

Pros: difference only [patch.crates-io] section,
also as this sections ignored in dependencies IMHO possible just publish crate from master branch

Cons:

  1. Totally incompatible with .cargo\config\path: cargo not allow mixing.
  2. If someone want use git version then he need use [patch.crates-io] too.
  3. Related errors unclear: in next error "0.7.0" is version of conflicting sys (not sure which)
error: failed to select a version for `gtk`.
    ... required by package `gtk-rs-examples v0.0.1 (file:///D:/eap/rust/0/examples)`
versions that meet the requirements `^0` are: 0.7.0

the package `gtk-rs-examples` depends on `gtk`, with features: `v3_22, v3_16, v3_20, v3_10, v3_22_30, v3_18` but `gtk` does not have these features.
@GuillaumeGomez
Copy link
Member

Still seems like a huge hack and the errors are clearly an issue from my point of view. Besides this, it seems very promising!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants