Files
zzet--gortex/scripts
Andrey Kumanyaev 1f7bf6ea48 release: link linux binaries statically so they run on any distro
The linux release was dynamically linked despite the README promising a
single static binary with no dependency chain. goreleaser-cross:v1.26 is
Ubuntu 24.04 / GCC 13.3, so the artifacts carried that host's floor —
GLIBCXX_3.4.32 and GLIBC_2.34 — and refused to start anywhere older:

  gortex: /lib/x86_64-linux-gnu/libstdc++.so.6:
          version `GLIBCXX_3.4.32' not found (required by gortex)

Debian 12 caps at GLIBCXX_3.4.30 and Ubuntu 22.04 at 3.4.29, so in practice
the binary only ran on Ubuntu 24.04+/Debian 13+. libstdc++ is in the link at
all because some tree-sitter grammars ship C++ external scanners. Windows
already linked -static; only linux was left dynamic.

Link -static with netgo, osusergo and static_link, which between them remove
every dlopen the binary would otherwise perform at runtime.

verify-static-elf.sh asserts no DT_NEEDED, no PT_INTERP and no symbol-version
requirements. It runs as a goreleaser build post-hook rather than a workflow
step because `goreleaser release` builds and publishes in the same run — a
check after it would only ever be a post-mortem on an already-published
artifact. The release job re-asserts it on the packaged tarballs and then
proves it by execution on debian:11 and alpine.
2026-07-26 17:23:21 +02:00
..
2026-04-27 22:54:42 +02:00
2026-05-21 08:31:11 +02:00
2026-05-07 13:45:48 +02:00