Hey, I’m new to Zig and trying to figure out how to port some Makefiles to its build system, and I’ve gotten stuck pretty quickly. There doesn’t seem to be much documentation on how to call executables from the Zig build system.
What I’m trying to do is build an executable
some-exe, then, as another step, generate a C file by running that execuable with a file piped to it (
some-exe < file.txt > out.c).
const someExe = b.addExecutable("some-exe", "main.c"); someExe.setTarget(target); someExe.setBuildMode(mode); someExe.linkLibC(); const generated = someExe.run() // ... now how do I pipe a file to this?