depfile 0.1.1

Simply parse .d files
Documentation
  • Coverage
  • 100%
    14 out of 14 items documented1 out of 14 items with examples
  • Size
  • Source code size: 33.4 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 3.73 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 18s Average build duration of successful builds.
  • all releases: 18s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Pistonite/depfile
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • Pistonight

depfile

Simply parse .d files.

use std::borrow::Cow;

fn main() {

    let input = r"
x.cpp.o: x.cpp \
  include/foo.h \
  include/bar.h
include/foo.h:
include/bar.h: fiz.h
";

    let targets = depfile::parse(input).expect("syntax error");
    for dep in targets.recurse_deps("x.cpp.o") {
        println!("x.cpp.o depends on: {dep}");
    }
}

See documentation on docs.rs