sqlc icon indicating copy to clipboard operation
sqlc copied to clipboard

add ARM releases

Open theRealWardo opened this issue 4 years ago • 5 comments

in https://github.com/kyleconroy/sqlc/issues/457 support for ARM was verified and indeed this package compiles for me on Apple silicon without a problem.

however, this project's releases do not include builds for darwin_arm64 nor linux_arm64. how can I help get those added for this project?

(ps. I'd file this as a like feature request or something but the only template I see is a bug report)

theRealWardo avatar Dec 03 '21 17:12 theRealWardo

I don't think this is currently possible. Release binaries are built using GitHub Actions. Until they support M1 machines, darwin_arm is off the table. I'm not sure about Linux ARM.

kyleconroy avatar Dec 07 '21 06:12 kyleconroy

I too would be very grateful if arm64 release is provided. 👍

k0kubun/sqldef is also written in Golang and it builds binaries including arm64 for both darwin and linux using GitHub Actions then publishes them to its GitHub Releases.

I hope it helps.

yuku avatar Jan 10 '22 03:01 yuku

The issue here is that sqlc depends on a few packages that use cgo, which makes cross-compiling difficult. Thankfully, I'm the new owner of an M1 MacBook, so I can build the darwin_arm64 targets locally. I'll need to create a self-hosted runner to package up and build the Linux ARM binaries.

kyleconroy avatar Jan 14 '22 03:01 kyleconroy

This would be wonderful to have!

maxekman avatar Mar 24 '22 06:03 maxekman

Considering the release doesn't happen too frequently, I would appreciate it if the release also included a manually built artifact for darwin-arm64.

I just manually edit the release for my projects and add binaries that cannot be built via OSS CI systems until we have an actual solution.

Malinskiy avatar Jul 25 '22 01:07 Malinskiy

still not see arm release in v1.15.0

solarhell avatar Sep 27 '22 10:09 solarhell

Took a bit longer than expected, but ARM releases have been added for Darwin for 1.16.0.

https://github.com/kyleconroy/sqlc/releases/download/v1.16.0/sqlc_1.16.0_darwin_arm64.tar.gz

kyleconroy avatar Nov 21 '22 02:11 kyleconroy

Looks like there was an issue with signing the releases for v1.16.0, removing them for now

kyleconroy avatar Nov 21 '22 03:11 kyleconroy

Okay, all fixed now. I also automated the process so we'll have darwin_arm64 releases going forward.

Do people also need ARM releases for Linux?

kyleconroy avatar Nov 26 '22 20:11 kyleconroy

Linux ARM binaries have been added for the last two releases, v1.17.2 and v1.18.0. They're also available via https://downloads.sqlc.dev:

https://downloads.sqlc.dev/sqlc_1.17.2_linux_arm64.tar.gz https://downloads.sqlc.dev/sqlc_1.18.0_linux_arm64.tar.gz

kyleconroy avatar Jun 10 '23 00:06 kyleconroy

Really fast! Thanks! 🚀

before

$ time go install github.com/kyleconroy/sqlc/cmd/[email protected] 
real    0m28.474s
user    0m55.467s
sys     0m10.388s

after

$ time curl -fsL https://downloads.sqlc.dev/sqlc_1.18.0_linux_arm64.tar.gz | tar -C /bo/bin -xzf -
real    0m4.568s
user    0m1.142s
sys     0m0.861s

yuku avatar Jun 15 '23 01:06 yuku