Hacker News new | ask | show | jobs
by networked 1187 days ago
> All is included in a single binary. Very few external dependencies (Python is not needed) so installation is easy on most Linux distributions.

I have to disagree. The combination of being closed-source and dynamically linked makes a program a hassle to run on Linux. Even if it isn't at the moment of release, it soon becomes one. While ts_server is better than most, it already requires an old version of libjpeg-turbo not available in my distribution's repositories. I had to run it in a Rocky Linux container:

  docker run \
    --rm \
    --mount type=bind,source="$(pwd)",target=/app/ \
    --publish 127.0.0.1:8080:8080 \
    rockylinux:9 \
    sh -c 'dnf install -y libjpeg libmicrohttpd && cd /app/ && ./ts_server ts_server.cfg'
The solutions to this problem that I am aware of that do not involve releasing the source code are: 1) static linking; 2) containers; 3) shipping a Windows binary :-) ("Win32 is the only stable ABI on Linux" -- https://blog.hiler.eu/win32-the-only-stable-abi/).
1 comments

The ABI doesn't seem to be the problem, and Win32 does not include a libjpeg, so your Win32 approach would only work if it also bundles or statically links libjpeg.
> your Win32 approach would only work if it also bundles or statically links libjpeg.

Of course. The stable ABI is to allow your bundled DLLs to keep functioning. (Check out https://news.ycombinator.com/item?id=32471624 for an extensive discussion of the link.)