glibc is bloated and produces bloated binaries. It is also hostile to static linking - glibc programs will still rely on dynamic linking even when compiled with -static.


[sircmpwn@homura tmp.r4ooMD1YSE]$ cat test.c
int main() {
    return 0;
[sircmpwn@homura tmp.r4ooMD1YSE]$ cc -static test.c
[sircmpwn@homura tmp.r4ooMD1YSE]$ wc -c a.out 
810264 a.out
[sircmpwn@homura tmp.r4ooMD1YSE]$ objdump -t a.out | grep dlopen
0000000000465f70 l     F .text  000000000000003a do_dlopen
0000000000000000 l    df *ABS*  0000000000000000 sdlopen.o
0000000000473e40 l     F .text  0000000000000071 dlopen_doit
0000000000473ec0 g     F .text  000000000000006a __dlopen
0000000000466230 g     F .text  0000000000000080 __libc_dlopen_mode
[sircmpwn@homura tmp.r4ooMD1YSE]$

musl libc

[sircmpwn@cirno tmp.LhOGLL]$ cat test.c
int main() {
    return 0;
[sircmpwn@cirno tmp.LhOGLL]$ cc -static test.c
[sircmpwn@cirno tmp.LhOGLL]$ wc -c a.out
8256 a.out
[sircmpwn@cirno tmp.LhOGLL]$ objdump -t a.out | grep dlopen
[sircmpwn@cirno tmp.LhOGLL]$

GNU coreutils

GNU coreutils is also bloated. This is firstly due to software design (GNU code is gross), but also because they include many non-standard extensions and encourage writing non-portable scripts.

GNU coreutils: 13.76 MiB (dynamically linked)

Busybox: 232 KiB (statically linked)

Busybox was compiled only with support for programs included with GNU coreutils.