I’m pleased to share this informal case study of work we’ve done to use the Zig build system to build an isolated and repeatable collection of R packages and their dependencies from source, along with JavaScript bundles. I’m sure there are many improvements possible, but it was an enjoyable challenge to work with the Zig build system for this non-Zig project. Feedback and suggestions are welcome!
From the article:
The Zig solution developed has these parts:
- a code generator that generates a build.zig file
- an asset fetcher that downloads binary assets and confirms hashes
- an R-specific library which imports package repositories to generate and validate a repeatable build plan for a local collection of packages and their dependencies
Full text:
Case study: using Zig build system to build a complex R and JavaScript project