Hacker News new | ask | show | jobs
by sprash 2586 days ago
Always use musl for static linking. As a bonus you might get an even smaller binary than a dynamically linked glibc binary.
1 comments

Keep in mind, however, that AFAIK musl won't respect /etc/nsswitch.conf, so if for instance the machine is configured to lookup users on ldap, a musl static linked program won't be able to correctly lookup users.
There are certainly cases where you need the features of glibc over musl, but those are pretty rare IMO, and you can always implement a missing piece yourself if using musl saves you enough in maintenance overhead.