#1120·caveman

Release binaries compress Go only (CGO_ENABLED=0); please consider cgo variants

Author: sebastianrueckeraiCreated Sep 24, 2026Updated Sep 26, 2026

The release binaries build with CGO_ENABLED=0. Without cgo the engine links no tree-sitter, so the compressor elides Go only. Python, TypeScript, C, C++, Rust and Java pass through untouched. Go works because the Go standard library carries a Go parser. Every other language needs tree-sitter, which is C.

I measured what a cgo build of the same code does. Build: tag bin-v1.1.7 plus three pull requests (#1076 GDScript, #1077 TSX, #1078 C++), CGO_ENABLED=1, o200k tokens:

file before (o200k) after (o200k) cut
GDExtension kernel .cpp, needs #1078 18,112 3,847 79%
GDScript file, needs #1076 1,229 465 62%
Python module 1,391 802 42%
React .tsx component, needs #1077 183 71 61%
Go file 9,991 1,949 80%

The Go row is a reference. It compresses in the CGO_ENABLED=0 build too.

I run this cgo build instead of the release binaries, so I rebuild after each release. That works, but it keeps multi-language compression out of the default install, and #1076 and #1078 have no effect without a cgo build.

Would you consider shipping cgo variants next to the current binaries, for some or all of the six targets? If the cross-build is the cost, I can contribute the pipeline. The zig cc cross-compiler builds static cgo binaries for all six targets from one Linux runner, and the pure binaries with their signed manifest would stay untouched.