Hacker News new | ask | show | jobs
by dTal 1501 days ago
> How do I get my application to my users? For historical reasons, there hasn't been a good answer to this question for a long, long time

What is wrong with a binary in a tarball, like Firefox and Blender and VSCode and everyone else uses? This always seemed like a non-problem to me.

1 comments

Linker errors
You just bundle all libraries except glibc in the tarball. You build against the oldest glibc you're willing to call "supported". Firefox and Blender (among many others) have been doing this for as long as I can remember, and as long as I can remember their tarballs have never failed to work for me, on any distro.

The problem seems to me to be that there's some kind of cultural imperative to attempt to dynamically link against whatever the system version of a library is, which is clearly insanity.

Static linking.
You can't statically link glibc and you shouldn't statically link openssl or libcrypto, and Linux distributions make it extremely difficult to do reliably without compiling everything from source.
You don't have to statically link everything. You should choose based on (a) if the lib has to be dynamic (eg. portability layers, crypto) (b) if the lib is widespread and has stable ABI.
and now your tarball will break on an indeterminate number of linux user machines without (often extensive) manual intervention to fix .so versioning issues. That's why things like flatpak exist.