4 ms·
> Death to shared libraries. The headaches they cause are just not worth the benefit. Completely disagree. Even though one size does not fit all, anyone who ma
by arinlen 4y ago
> Death to shared libraries. The headaches they cause are just not worth the benefit.
Completely disagree. Even though one size does not fit all, anyone who makes sweeping statements about static libraries is just stating to the world how they are completely oblivious regarding basic software maintenance problems such as tracking which software package is updated, specially those who are not kept up to date on a daily basis.
- waynecochran 4y agoI like the old school days of just building everything from source. Similarly the Linux Kernel was statically built -- before modules. I knew the whole system from top to bottom.
- nicoburns 4y agoIf there was a standard for specifying which static library a binary has linked, this would be a non-issue.
- arinlen 4y ago> If there was a standard for specifying which static library a binary has linked, this would be a non-issue. You just gave a non-sequitur answer that rings as rational and true as stating that if the Pope would fly he would be an Airbus A330. Limiting which static library you can link to means absolutely nothing to the problems created by static linking, and how shared libraries solve all of them without any meaningful tradeoff at all.
- CuriousCosmic 4y agoIn a sense there kinda is. Pre-linking is a way to statically specify the lookup for a given shared library in an ELF executable. It's still kinda dynamic linking because the file is loaded at runtime but there's no library lookup, it's just "load this file at this path into address space while we load the rest of the main executable". Before PIC there would have been a bit more of a distinction but nowadays static and dynamic libraries are really only distinguished by where the symbols are (unless you want to be able to dynamically load and unload after startup).
- deleted 4y ago[deleted]
- mariusor 4y agoI'd say this is a solved problem. It's easy to get all build dependencies of a package and for every library that gets updated you build the world. It's a more computing power and bandwidth that is required, but the maintenance burden is mostly solved by now by modern package managers or tooling on top of not so modern ones.
- benreesman 4y agoDynamic linking by default has been vocally criticized by everyone from Carmack to Bell Labs/Plan9/golang people. Many if not most of the big scale companies have historically avoided it like the plague. It has horrific costs in performance, security, reproducibility, and ultimately comprehensibility of any system. People pay out the ass in droves via Docker (huge-ass images, clunky composability, cgroup/namespace complexity) and Nix (horror-movie learning curve) and I'm sure other things to get around it / emulate static linking. `sudo apt-whatever upgrade` and pray is pretty much DOA in even low-complexity settings. People are voting with their feet. You can disagree, and if you're not affiliated with Debian or GNU I might even believe that you come by that opinion honestly, but this gigantic bloc of people who hate it are not all "oblivious".
- pjmlp 4y agoBell Labs introduced shared objects into UNIX, maybe they should have learned better from other platforms.
- benreesman 4y agoThey realized that they had goofed like 25-30 years ago and have been battling their own monster ever since: http://harmful.cat-v.org/software/dynamic-linking/versioned-symbols http://harmful.cat-v.org/software/dynamic-linking/versioned-.... I take the authors of a disaster more seriously when they say it's a disaster, not less.
- paskozdilar 4y agoDynamic linking is just poor man's IPC.