3 ms·
fully static (including libc) can cause a lot of trouble on Linux. Static binaries (with system libc) on Linux are okayish, if all the systems are the same dis
by dom0 10y ago
fully static (including libc) can cause a lot of trouble on Linux.
Static binaries (with system libc) on Linux are okayish, if all the systems are the same distro, or at least have a libc of the same vintage, but breaks frequently if you try to go further (eg. deploying to LTS distros like deb oldstable, centos, ...).
Doesn't really compare to eg. Windows, where you just bundle the MSVCRT with the installer and unless you're API incompatible the application will just work everywhere.
- UtherII 10y agoThat's why on Linux, by default, Rust link everything statically except the libc. But you sill can make a fully static executable by using the "musl" target.