You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My project contains two subdirectories of src, liba and libb. Both of them contain lib.rs. libb depends on liba. Inside the libb folder is a folder called test which contains test.rs and depends on the contents of libb. When building with rustpkg, libb is compiled ad infinitum as it tries to resolve its dependency.
Reproduced with HEAD. Note that this happens even with just a self-contained libb, as long as the test subdirectory with the test.rs file depending on libb is there.
I think the Right Thing is for rustpkg to topologically sort crates in the given package by dependency order. This will be a bit of work, since as it is, we don't have a graph library.
Having slept on this, I think the situation isn't really so bad. The problem is that I'm considering a given package to be a single unit. Thus, the containing package here doesn't show up in workcache as "already built". If I cached each crate as a single entity with inputs and outputs, I think this example would work without having to build a dependency graph. (Building a dependency graph would be more declarative, and workcache is supposed to work imperatively, which occurred to me later.)
Activity
huonw commentedon Jul 18, 2013
cc @catamorphism
catamorphism commentedon Sep 12, 2013
Reproduced with HEAD. Note that this happens even with just a self-contained
libb, as long as thetestsubdirectory with thetest.rsfile depending on libb is there.catamorphism commentedon Sep 12, 2013
I think the Right Thing is for rustpkg to topologically sort crates in the given package by dependency order. This will be a bit of work, since as it is, we don't have a graph library.
catamorphism commentedon Sep 13, 2013
Having slept on this, I think the situation isn't really so bad. The problem is that I'm considering a given package to be a single unit. Thus, the containing package here doesn't show up in workcache as "already built". If I cached each crate as a single entity with inputs and outputs, I think this example would work without having to build a dependency graph. (Building a dependency graph would be more declarative, and workcache is supposed to work imperatively, which occurred to me later.)
rustpkg: Make crates, not packages, the unit of rustpkg dependencies
auto merge of #9263 : catamorphism/rust/rustpkg-issue-7879, r=brson
Merge rust-lang#7879