-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Error compiling fyne on Apple M1 arm64 #1739
Comments
Do you have Xcode and the command line tools all installed? We have not yet tested compiling on an M1 so this may be a new issue. |
Can you please update the issue with the contents from the issue template? The issue template is there for us to more easily be able to help. More specifically, I am curious about the Go version that you are using. Go 1.16 (which has yet to be released) is the first release with M1 support and the older versions do not support compilation for that target. |
Added system and Golang info.
Sure, everything is installed. |
Hmm, looking closer it seems we are trying to load a GLES driver because it’s an arm machine. Apple must, if at al, be using core OpenGL for compatibility so we need an M1 specific compile option. |
Yeah, I can. Could you point an example to check this idea with? |
I don't have a list personally - but I saw a few listed on Reddit: https://www.reddit.com/r/macgaming/comments/jvlpmi/stardew_valley_an_opengl_game_runs_fine_on_apple/ |
Used this tutorial: https://kylewbanks.com/blog/tutorial-opengl-with-golang-part-1-hello-opengl It compiles and works with that triangle. 2021-01-12.10.23.35.mp4 |
It looks like glfw isn't working on M1 just yet. See this PR for more info: glfw/glfw#1833 |
I think it is a long life time issue go-gl/gl#125 |
It might be the opposite issue - on that ticket they want to use GLES but it's not included, whereas the issue here we have is that when on arm we auto-detect GLES but we want to use OpenGL proper. Could you please help us @sirkon, by inverting the "arm" flag in |
@andydotxyz @sirkon Thanks for your suggestion. With inverting the "arm" and "arm64" flag in internal/painter/gl/gl_es.go and gl_core.go, the program can build success, but still not start normally: it does not show main screen with some warnings and errors:
|
@andydotxyz confirm @ipfans report, it compiles but no GUI is shown with the same error message: "OpenGL ES not available on macOS" |
BTW, returned back finally to my intel machine. Really like the overall feel of the library, just what is needed for my tasks, good job, thank you! PS Hope to see working M1 sooner than later :) |
I have this problem too. I'm using mac M1. |
If anyone is able to share access to an M1 it may get fixed sooner - because none of the developers currently have access. |
And it works! 2021-02-07.15.36.36.mp4PS A bit harder than just toggling arm tags. Got an idea though, just managed to enable _core and disable _es and that worked. |
Is it possible without a public IP? I guess I could share an access if it is possible somehow without a public address. |
This is fantastic news, thanks. Can you please share the diff here so we can work with it?
Not really, but don't worry - you have it working, so we can work with your differences and if you're able to test a patch once we have a PR shaped up that's just as good as direct access! |
Made a PR #1922 |
Fixed on |
For my old MBP, branch develop won't work. I created a vendor directory, and download develop branch in it. Then run commands below. go mod vendor reports nothing. but when I try to run it, there is an error output below.
go version go1.16.5 darwin/amd64 |
Go mod vendor overwrites your vendor folder. And it is not needed for go 1.16. You need to update the version in your go.mod to head of develop branch and it should just work |
FYI this may relate to #2282 - by calling |
Cannot compile fyne_demo on Apple M1 (if it matters).
I am following the procedure described at the tour, got an error message:
Device (please complete the following information):
The text was updated successfully, but these errors were encountered: