You don't need CGO to use SQLite in your Go binary
At least not for most use cases. You can just use modernc.org/sqlite instead as your SQLite driver. For people who aren’t in the Go know, “pure” Go programs are trivially easy to compile cross-platform to all the major platforms by default. You read that right - you can just go build a single Windows executable, Mac executable, and Linux executable on the same machine and just ship it: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 # This can all happen on the same box! export CGO_ENABLED=0 # no c cross-compilation please export GOOS=linux GOARCH=amd64 go build -o hello-linux-amd64 hello.go GOARCH=arm64 go build -o hello-linux-arm64 hello.go export GOOS=darwin # aka mac GOARCH=amd64 go build -o hello-darwin-amd64 hello.go GOARCH=arm64 go build -o hello-darwin-arm64 hello.go export GOOS=windows GOARCH=amd64 go build -o hello-windows-amd64.exe hello.go GOARCH=arm64 go build -o hello-windows-arm64.exe hello.go This was the real reason I chose Go over Python for tsk, my instant-search Finnish to English pocket dictionary. I wanted to be able to give Windows users a single .exe they could just run and have work out of the box. ...