3 ms·
Here is a web page comparing the different C library implementations: http://www.etalabs.net/compare_libcs.html http://www.etalabs.net/compare_libcs.html For
by dottrap 7y ago
Here is a web page comparing the different C library implementations:
http://www.etalabs.net/compare_libcs.html http://www.etalabs.net/compare_libcs.html
For the .a size:
musl: 426k
uClibc: 500k
dietlibc: 120k
If you statically link to these, your final binary will only pull what is actually needed and be smaller than this.
- BubRoss 7y agoI know they are smaller, but why are they able to only pull in what you use when other libc implementations can't?
- dottrap 7y agoAny that allows static linking will get the same benefit. For the three mentioned in the ancestor thread: Apple doesn't ship a static libc, so developers must dynamically link. glibc does allow static linking, but it is something they don't really go out of their way to promote and I recall some historic pains trying to get it to work right. Maybe that all works better today. MSVC does allow static linking to msvcrt. MSVC is a little different than other platforms because they have permutations (and associated rules) you must be aware of: [debug | release], [static | dynamic], [single-threaded | multithreaded].