-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
causing sql-migrate installation failed using go get in Apple Silicon #904
Comments
Have you tried compiling any other cgo code? Does that work fine? |
I am not that proficient in both c and go language, I don't know how to do it. But I download the go-sqlite3 and run What should I do then? |
You can test with a simple program like:
What is the size of the
The error message:
Makes it sound like there's something wrong with the C compiler on your system – it tries to link against amd64(?) I don't really have experience on macOS systems, and certainly not on the new ARM systems. |
|
Now the error is the other way:
If I search for that error, I end up on e.g. the Go issue, and people are getting these kind of errors if they use Go 1.15 on the new ARM machines. Are you sure you're using Go 1.16? What does |
and
|
How about plain C/C++ compilation? For C (compile with
And C++ (compile with
Does that work fine? |
Yes, it works fine! the previous c code produced |
Hmm. And so the toy cgo example arp242 posted above fails? What if you force-rebuild everything with (oh, and |
|
Right. Well, next step would be to try |
yes, it works, but it doesn't produce Although I still have no sense of what happened. But I am really appreciated. |
Ah, good to hear! go-sqlite3 is a library, not a standalone program, so it won't produce a Not sure what happened: my guess is something broken in your build cache (so fixed by doing |
(P.S. You should probably close the issue if your problem is resolved.) |
Really appreciate your help, I will close it. |
I try to install sql-migrate in macos 11.1, Apple M1 chip. My go version is
Go.1.16Beta1
I have also tried
env GOOS=darwin CGO_ENABLED=1 GOARCH=arm64 go get -v github.com/rubenv/sql-migrate/sql-migrate
, but it is not functional.The blame seems to lie with go-sqlite3.
Can someone help me?
The text was updated successfully, but these errors were encountered: