Skip to content

Latest commit

 

History

History
22 lines (14 loc) · 863 Bytes

README.md

File metadata and controls

22 lines (14 loc) · 863 Bytes

nim2-buildroot-toolchain

This project provides a Docker buildroot cross-compilation toolchain for building fully static musl executables for C/C++ and Nim.

Static linking results in binaries that have all the necessary libraries bundled within, eliminating dependency issues, and runs on any Linux distribution.

Support for openssl, pcre, tree-sitter, libpq, libgit2, libmagic, xxhash, libcurl, libsqlite is included and more.

Usage

# build buildroot and toolchain images
just build-buildroot build-toolchain build-nim

# build nim program
docker run -ti --rm -u docker -v $(pwd):$(pwd) -w $(pwd) nim-2.0.0 c test.nim

References

  • just - used for building project
  • earthly - make for docker