Eliminating build dependency on Go
- Dominant language
- Rust
- Stars
- 1.1k
- Forks
- 42
- PR merge metrics
- No merged PRs in 30d
Description
Currently, building Mundane requires Go 1.11+. Utilities in Go are used for three tasks:
1. Generating the interned error message bundle and its index (`crypto/err_data.c` in the build tree, from `crypto/err/*.errordata` in the source tree).
2. Extracting the names of public symbols from the archive created in the first library build (`crypto/libcrypto.a`) and saving the result in `symbols.txt` above the two build directories.
3. Generating the headers with substitutions from regular to versioned symbol names, using the result of the previous utility.
Those are rather simple programs and I have reimplemented them in Rust without much difficulty. Integrating them into `build.rs` could lead to elimination of Go as a build dependency of Mundane. While having any single dependency is not particularly onerous, I believe that minimizing their number eases the acceptance of a package, both for developers and end users. Even more so since Go 1.11 is not available on current LTS versions of popular distros.
Would there be any interest of pursuing this further?
Contributor guide
Research direction
Start with build.rs and the existing Go utilities, then trace how crypto/err/*.errordata produces crypto/err_data.c, how crypto/libcrypto.a produces symbols.txt, and how the generated headers are consumed. Compare the proposed Rust implementations with these build steps; done means the same artifacts and symbol substitutions are generated without requiring Go.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, rust
- Domain
- build-system, tooling
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100