Closed AlvaroMS25 closed 5 months ago
Hi! Do you mean RUSTFLAGS
?
You can set the value in .cargo/config.toml
to avoid using the env variable.
Using the env variable is a bit tricky because ideally you want to add the variable to the actual run step which is local to the function and is not available on the call site. But you can set the variable globally for the whole build graph:
b.graph.env_map.put("RUSTFLAGS", "flags go here") catch @panic("OOM");
Or set the value before running zig build
(assuming *nix shell):
RUSTFLAGS="flags go here" zig build
That was it, thanks!
Hello!, i'm using this library to build a rust project alongside a zig one, but i need to set
RUST_FLAGS
in order to compile the rust one, how can i do that?