Hi. If there is one area of zig that keeps giving me problems its the build files. I’m trying to build zig-miniaudio which was last updated 3 years ago so I guess its on a fairly old version of Zig. It would be pretty helpful if at the top of build files it would say what version was used. I’ve tried 10.1 and 11 but both fail and from the documentation I can’t figure out what I should change.
The first error is on this line.
const compile_type: enum { pre_compiled, compiled } = if (std.builtin.os.tag == .windows) .pre_compiled else .compiled;
error: root struct of file ‘builtin’ has no member named ‘os’
In the docs I can see that builtin is a namespace and os also a namespace but in different versions. However os namespace has no .tag. Zig helpfully says use fmt to update files but that seems to do nothing. Can anyone point me in the right direction please.