
Our intent is to enable us to move quickly, while also helping you to update your code. Thanks for readingĪs we work towards Mach v0.2, we’re getting more serious about what stability means for us. We’ve just gone for an initial 1:1 translation in our code, but adoption of the package manager will likely mean structuring your code a bit differently than the above, and the package manager is still a work-in-progress. You may also like to know that a pair of dependency name + the module can be represented as now. It will make the module available to other packages which depend on this package. Notably, modules are created at runtime via the *std.Build now - so you may have some reworking to do if you previously depended on being a global constant you could rely on at comptime.Īnother option, which may be preferred, is via addModule. It’s been renamed to b.standardOptimizeOption(.) Īnd then depend on that module using e.g. Previously you would’ve used b.standardReleaseOptions() which would provide your zig build command with multiple options like zig build -Drelease-fast=true, zig build -Drelease-safe=true, etc. Release options have been renamed to optimization What we have done, though, is updated to the latest API and want to share those changes with you. Mach isn’t yet using the new package manager: it’s improving rapidly, and we plan to make use of it soon, but things are still changing so we’ve held off for now.

You can get an overview of progress on the package manager on this GitHub project board Zig plans to run the build system in a sandboxed WASM environment ( #14286).The caching system is being moved from the compiler to the std lib to start using it in the bulid system ( #14571).Zig Object Notation (ZON, an alternative to JSON) was introduced ( #14523).“zig build: The breakings will continue until morale improves.” ( #14498).Transitive dependencies are now handled better ( #14392).

Zig packages can now expose C headers are part of their public API ( #14449).The package manager MVP landed almost a month ago and has seen steady improvements since ( #14265).

Zig is finally starting to see its package manager and build system shape up, some notable mentions: We’ve just updated Mach engine to use the latest Zig nightly version, which includes a fair amount of improvements and breaking changes to the std.build API used in build.zig files, and figured now would be a good time to share the general changes you may need to make if you want to update your own code.
