| Crates.io | maker |
| lib.rs | maker |
| version | 0.0.2 |
| created_at | 2025-06-25 13:30:18.448215+00 |
| updated_at | 2025-07-08 12:57:23.034608+00 |
| description | Generic Rusty declarative build system like GNU Make |
| homepage | |
| repository | https://github.com/e792a8/maker |
| max_upload_size | |
| id | 1725827 |
| size | 9,625 |
Generic Rusty declarative build system, like GNU Make.
Allows writing some Makefile-like rules, e.g.
let obj = Target::new_file("main.o")
.depends_on_file("main.c")
.recipe(|target, deps| {
Command::new("gcc")
.arg("-o")
.arg(target)
.args(deps)
.status()
.unwrap();
});
let bin = Target::new_file("main")
.depends_on_target(obj)
.recipe(|target, deps| {
Command::new("ld")
.arg("-o")
.arg(target)
.args(deps)
.status()
.unwrap();
});
bin.make();
... which is equivalent to the Makefile:
main.o: main.c
gcc -o $@ $^
main: main.0
ld -o $@ $^
... but see that .recipe() function? We can not only write shell scripts there, but also do more things fun and cross-platform (meanings of generic) -- in Rust!
In the hope that it will be useful in build.rs and xtask.