Hacker News new | ask | show | jobs
by thijsc 3450 days ago
I know from experience that it is possible to build Rust binaries that work on very old Linux versions. You could for example supply them with a Docker image with a new build stack which can produce binaries they could copy to the old machines. The same is likely true for Go.
1 comments

Unfortunately docker couldn't be used on RHEL5, it requires 3.10 or newer. But a disk image/qemu could work.
You can just give a chroot. At a company I used to work for, our build system used a chroot with a bunch of rarely-changing binaries/headers that let us build binaries for old distros, and then the directory with the actual code you were working on got bind-mounted into that chroot. The build process didn't depend on anything at all from the host system except for the build tool itself that set up the chroot environment. Everything to actually do the build (compiler, headers, utilities) lived in source control and was put into the build environment from there, so builds were 100% reproducible.